var sb=Object.create;var sp=Object.defineProperty;var cb=Object.getOwnPropertyDescriptor;var fb=Object.getOwnPropertyNames;var mb=Object.getPrototypeOf,pb=Object.prototype.hasOwnProperty;var hb=(e,t,a)=>()=>{if(a)throw a[0];try{return e&&(t=e(e=0)),t}catch(n){throw a=[n],n}};var Ft=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(a){throw t=0,a}};var gb=(e,t,a,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let l of fb(t))!pb.call(e,l)&&l!==a&&sp(e,l,{get:()=>t[l],enumerable:!(n=cb(t,l))||n.enumerable});return e};var k=(e,t,a)=>(a=e!=null?sb(mb(e)):{},gb(t||!e||!e.__esModule?sp(a,"default",{value:e,enumerable:!0}):a,e));var bp=Ft(U=>{"use strict";/** * @license React * react.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Qd=Symbol.for("react.transitional.element"),xb=Symbol.for("react.portal"),yb=Symbol.for("react.fragment"),vb=Symbol.for("react.strict_mode"),Lb=Symbol.for("react.profiler"),bb=Symbol.for("react.consumer"),Sb=Symbol.for("react.context"),Cb=Symbol.for("react.forward_ref"),wb=Symbol.for("react.suspense"),Ib=Symbol.for("react.memo"),hp=Symbol.for("react.lazy"),kb=Symbol.for("react.activity"),cp=Symbol.iterator;function Eb(e){return e===null||typeof e!="object"?null:(e=cp&&e[cp]||e["@@iterator"],typeof e=="function"?e:null)}var gp={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},xp=Object.assign,yp={};function Jn(e,t,a){this.props=e,this.context=t,this.refs=yp,this.updater=a||gp}Jn.prototype.isReactComponent={};Jn.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Jn.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function vp(){}vp.prototype=Jn.prototype;function Wd(e,t,a){this.props=e,this.context=t,this.refs=yp,this.updater=a||gp}var Jd=Wd.prototype=new vp;Jd.constructor=Wd;xp(Jd,Jn.prototype);Jd.isPureReactComponent=!0;var fp=Array.isArray;function Zd(){}var oe={H:null,A:null,T:null,S:null},Lp=Object.prototype.hasOwnProperty;function es(e,t,a){var n=a.ref;return{$$typeof:Qd,type:e,key:t,ref:n!==void 0?n:null,props:a}}function Mb(e,t){return es(e.type,t,e.props)}function ts(e){return typeof e=="object"&&e!==null&&e.$$typeof===Qd}function Ab(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(a){return t[a]})}var mp=/\/+/g;function $d(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Ab(""+e.key):t.toString(36)}function Db(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(Zd,Zd):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function Wn(e,t,a,n,l){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var r=!1;if(e===null)r=!0;else switch(o){case"bigint":case"string":case"number":r=!0;break;case"object":switch(e.$$typeof){case Qd:case xb:r=!0;break;case hp:return r=e._init,Wn(r(e._payload),t,a,n,l)}}if(r)return l=l(e),r=n===""?"."+$d(e,0):n,fp(l)?(a="",r!=null&&(a=r.replace(mp,"$&/")+"/"),Wn(l,t,a,"",function(d){return d})):l!=null&&(ts(l)&&(l=Mb(l,a+(l.key==null||e&&e.key===l.key?"":(""+l.key).replace(mp,"$&/")+"/")+r)),t.push(l)),1;r=0;var i=n===""?".":n+":";if(fp(e))for(var u=0;u{"use strict";Sp.exports=bp()});var Np=Ft(de=>{"use strict";/** * @license React * scheduler.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */function os(e,t){var a=e.length;e.push(t);e:for(;0>>1,l=e[n];if(0>>1;nVi(i,a))uVi(d,i)?(e[n]=d,e[u]=a,n=u):(e[n]=i,e[r]=a,n=r);else if(uVi(d,a))e[n]=d,e[u]=a,n=u;else break e}}return t}function Vi(e,t){var a=e.sortIndex-t.sortIndex;return a!==0?a:e.id-t.id}de.unstable_now=void 0;typeof performance=="object"&&typeof performance.now=="function"?(Cp=performance,de.unstable_now=function(){return Cp.now()}):(as=Date,wp=as.now(),de.unstable_now=function(){return as.now()-wp});var Cp,as,wp,ta=[],ka=[],Rb=1,Lt=null,Fe=3,rs=!1,co=!1,fo=!1,is=!1,Ep=typeof setTimeout=="function"?setTimeout:null,Mp=typeof clearTimeout=="function"?clearTimeout:null,Ip=typeof setImmediate<"u"?setImmediate:null;function Xi(e){for(var t=jt(ka);t!==null;){if(t.callback===null)Ki(ka);else if(t.startTime<=e)Ki(ka),t.sortIndex=t.expirationTime,os(ta,t);else break;t=jt(ka)}}function us(e){if(fo=!1,Xi(e),!co)if(jt(ta)!==null)co=!0,tl||(tl=!0,el());else{var t=jt(ka);t!==null&&ds(us,t.startTime-e)}}var tl=!1,mo=-1,Ap=5,Dp=-1;function Tp(){return is?!0:!(de.unstable_now()-Dpe&&Tp());){var n=Lt.callback;if(typeof n=="function"){Lt.callback=null,Fe=Lt.priorityLevel;var l=n(Lt.expirationTime<=e);if(e=de.unstable_now(),typeof l=="function"){Lt.callback=l,Xi(e),t=!0;break t}Lt===jt(ta)&&Ki(ta),Xi(e)}else Ki(ta);Lt=jt(ta)}if(Lt!==null)t=!0;else{var o=jt(ka);o!==null&&ds(us,o.startTime-e),t=!1}}break e}finally{Lt=null,Fe=a,rs=!1}t=void 0}}finally{t?el():tl=!1}}}var el;typeof Ip=="function"?el=function(){Ip(ns)}:typeof MessageChannel<"u"?(ls=new MessageChannel,kp=ls.port2,ls.port1.onmessage=ns,el=function(){kp.postMessage(null)}):el=function(){Ep(ns,0)};var ls,kp;function ds(e,t){mo=Ep(function(){e(de.unstable_now())},t)}de.unstable_IdlePriority=5;de.unstable_ImmediatePriority=1;de.unstable_LowPriority=4;de.unstable_NormalPriority=3;de.unstable_Profiling=null;de.unstable_UserBlockingPriority=2;de.unstable_cancelCallback=function(e){e.callback=null};de.unstable_forceFrameRate=function(e){0>e||125n?(e.sortIndex=a,os(ka,e),jt(ta)===null&&e===jt(ka)&&(fo?(Mp(mo),mo=-1):fo=!0,ds(us,a-n))):(e.sortIndex=l,os(ta,e),co||rs||(co=!0,tl||(tl=!0,el()))),e};de.unstable_shouldYield=Tp;de.unstable_wrapCallback=function(e){var t=Fe;return function(){var a=Fe;Fe=t;try{return e.apply(this,arguments)}finally{Fe=a}}}});var Bp=Ft((X2,Rp)=>{"use strict";Rp.exports=Np()});var Op=Ft(Ve=>{"use strict";/** * @license React * react-dom.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Bb=z();function _p(e){var t="https://react.dev/errors/"+e;if(1{"use strict";function zp(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(zp)}catch(e){console.error(e)}}zp(),qp.exports=Op()});var Zx=Ft(vd=>{"use strict";/** * @license React * react-dom-client.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var ke=Bp(),sg=z(),zb=Gt();function w(e){var t="https://react.dev/errors/"+e;if(1ul||(e.current=Ys[ul],Ys[ul]=null,ul--)}function ae(e,t){ul++,Ys[ul]=e.current,e.current=t}var Yt=$t(null),Ho=$t(null),Ua=$t(null),Mu=$t(null);function Au(e,t){switch(ae(Ua,t),ae(Ho,e),ae(Yt,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Kh(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Kh(t),e=Ox(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}Te(Yt),ae(Yt,e)}function kl(){Te(Yt),Te(Ho),Te(Ua)}function $s(e){e.memoizedState!==null&&ae(Mu,e);var t=Yt.current,a=Ox(t,e.type);t!==a&&(ae(Ho,e),ae(Yt,a))}function Du(e){Ho.current===e&&(Te(Yt),Te(Ho)),Mu.current===e&&(Te(Mu),Qo._currentValue=Cn)}var ss,Pp;function vn(e){if(ss===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);ss=t&&t[1]||"",Pp=-1)":-1l||u[n]!==d[l]){var m=` `+u[n].replace(" at new "," at ");return e.displayName&&m.includes("")&&(m=m.replace("",e.displayName)),m}while(1<=n&&0<=l);break}}}finally{cs=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?vn(a):""}function Fb(e,t){switch(e.tag){case 26:case 27:case 5:return vn(e.type);case 16:return vn("Lazy");case 13:return e.child!==t&&t!==null?vn("Suspense Fallback"):vn("Suspense");case 19:return vn("SuspenseList");case 0:case 15:return fs(e.type,!1);case 11:return fs(e.type.render,!1);case 1:return fs(e.type,!0);case 31:return vn("Activity");default:return""}}function Fp(e){try{var t="",a=null;do t+=Fb(e,a),a=e,e=e.return;while(e);return t}catch(n){return` Error generating stack: `+n.message+` `+n.stack}}var Zs=Object.prototype.hasOwnProperty,Hc=ke.unstable_scheduleCallback,ms=ke.unstable_cancelCallback,jb=ke.unstable_shouldYield,Gb=ke.unstable_requestPaint,dt=ke.unstable_now,Vb=ke.unstable_getCurrentPriorityLevel,xg=ke.unstable_ImmediatePriority,yg=ke.unstable_UserBlockingPriority,Tu=ke.unstable_NormalPriority,Xb=ke.unstable_LowPriority,vg=ke.unstable_IdlePriority,Kb=ke.log,Yb=ke.unstable_setDisableYieldValue,tr=null,st=null;function Ba(e){if(typeof Kb=="function"&&Yb(e),st&&typeof st.setStrictMode=="function")try{st.setStrictMode(tr,e)}catch{}}var ct=Math.clz32?Math.clz32:Qb,$b=Math.log,Zb=Math.LN2;function Qb(e){return e>>>=0,e===0?32:31-($b(e)/Zb|0)|0}var Zi=256,Qi=262144,Wi=4194304;function Ln(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 nd(e,t,a){var n=e.pendingLanes;if(n===0)return 0;var l=0,o=e.suspendedLanes,r=e.pingedLanes;e=e.warmLanes;var i=n&134217727;return i!==0?(n=i&~o,n!==0?l=Ln(n):(r&=i,r!==0?l=Ln(r):a||(a=i&~e,a!==0&&(l=Ln(a))))):(i=n&~o,i!==0?l=Ln(i):r!==0?l=Ln(r):a||(a=n&~e,a!==0&&(l=Ln(a)))),l===0?0:t!==0&&t!==l&&(t&o)===0&&(o=l&-l,a=t&-t,o>=a||o===32&&(a&4194048)!==0)?t:l}function ar(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Wb(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 Lg(){var e=Wi;return Wi<<=1,(Wi&62914560)===0&&(Wi=4194304),e}function ps(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function nr(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Jb(e,t,a,n,l,o){var r=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 i=e.entanglements,u=e.expirationTimes,d=e.hiddenUpdates;for(a=r&~a;0"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var oS=/[\n"\\]/g;function It(e){return e.replace(oS,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Js(e,t,a,n,l,o,r,i){e.name="",r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"?e.type=r:e.removeAttribute("type"),t!=null?r==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+St(t)):e.value!==""+St(t)&&(e.value=""+St(t)):r!=="submit"&&r!=="reset"||e.removeAttribute("value"),t!=null?ec(e,r,St(t)):a!=null?ec(e,r,St(a)):n!=null&&e.removeAttribute("value"),l==null&&o!=null&&(e.defaultChecked=!!o),l!=null&&(e.checked=l&&typeof l!="function"&&typeof l!="symbol"),i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"?e.name=""+St(i):e.removeAttribute("name")}function Ag(e,t,a,n,l,o,r,i){if(o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"&&(e.type=o),t!=null||a!=null){if(!(o!=="submit"&&o!=="reset"||t!=null)){Ws(e);return}a=a!=null?""+St(a):"",t=t!=null?""+St(t):a,i||t===e.value||(e.value=t),e.defaultValue=t}n=n??l,n=typeof n!="function"&&typeof n!="symbol"&&!!n,e.checked=i?e.checked:!!n,e.defaultChecked=!!n,r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"&&(e.name=r),Ws(e)}function ec(e,t,a){t==="number"&&Nu(e.ownerDocument)===e||e.defaultValue===""+a||(e.defaultValue=""+a)}function Ll(e,t,a,n){if(e=e.options,t){t={};for(var l=0;l"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ac=!1;if(ha)try{al={},Object.defineProperty(al,"passive",{get:function(){ac=!0}}),window.addEventListener("test",al,al),window.removeEventListener("test",al,al)}catch{ac=!1}var al,_a=null,Xc=null,hu=null;function Bg(){if(hu)return hu;var e,t=Xc,a=t.length,n,l="value"in _a?_a.value:_a.textContent,o=l.length;for(e=0;e=Eo),Jp=" ",eh=!1;function Og(e,t){switch(e){case"keyup":return RS.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function zg(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var cl=!1;function _S(e,t){switch(e){case"compositionend":return zg(t);case"keypress":return t.which!==32?null:(eh=!0,Jp);case"textInput":return e=t.data,e===Jp&&eh?null:e;default:return null}}function OS(e,t){if(cl)return e==="compositionend"||!Yc&&Og(e,t)?(e=Bg(),hu=Xc=_a=null,cl=!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)return{node:a,offset:t-e};e=n}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=lh(a)}}function Pg(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Pg(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Fg(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Nu(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=Nu(e.document)}return t}function $c(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 GS=ha&&"documentMode"in document&&11>=document.documentMode,fl=null,nc=null,Ao=null,lc=!1;function rh(e,t,a){var n=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;lc||fl==null||fl!==Nu(n)||(n=fl,"selectionStart"in n&&$c(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Ao&&jo(Ao,n)||(Ao=n,n=Zu(nc,"onSelect"),0>=r,l-=r,Vt=1<<32-ct(t)+l|a<N?(A=I,I=null):A=I.sibling;var T=g(x,I,y[N],L);if(T===null){I===null&&(I=A);break}e&&I&&T.alternate===null&&t(x,I),p=o(T,p,N),E===null?M=T:E.sibling=T,E=T,I=A}if(N===y.length)return a(x,I),G&&ia(x,N),M;if(I===null){for(;NN?(A=I,I=null):A=I.sibling;var B=g(x,I,T.value,L);if(B===null){I===null&&(I=A);break}e&&I&&B.alternate===null&&t(x,I),p=o(B,p,N),E===null?M=B:E.sibling=B,E=B,I=A}if(T.done)return a(x,I),G&&ia(x,N),M;if(I===null){for(;!T.done;N++,T=y.next())T=f(x,T.value,L),T!==null&&(p=o(T,p,N),E===null?M=T:E.sibling=T,E=T);return G&&ia(x,N),M}for(I=n(I);!T.done;N++,T=y.next())T=h(I,x,N,T.value,L),T!==null&&(e&&T.alternate!==null&&I.delete(T.key===null?N:T.key),p=o(T,p,N),E===null?M=T:E.sibling=T,E=T);return e&&I.forEach(function(le){return t(x,le)}),G&&ia(x,N),M}function C(x,p,y,L){if(typeof y=="object"&&y!==null&&y.type===il&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case $i:e:{for(var M=y.key;p!==null;){if(p.key===M){if(M=y.type,M===il){if(p.tag===7){a(x,p.sibling),L=l(p,y.props.children),L.return=x,x=L;break e}}else if(p.elementType===M||typeof M=="object"&&M!==null&&M.$$typeof===Ma&&bn(M)===p.type){a(x,p.sibling),L=l(p,y.props),xo(L,y),L.return=x,x=L;break e}a(x,p);break}else t(x,p);p=p.sibling}y.type===il?(L=wn(y.props.children,x.mode,L,y.key),L.return=x,x=L):(L=xu(y.type,y.key,y.props,null,x.mode,L),xo(L,y),L.return=x,x=L)}return r(x);case So:e:{for(M=y.key;p!==null;){if(p.key===M)if(p.tag===4&&p.stateNode.containerInfo===y.containerInfo&&p.stateNode.implementation===y.implementation){a(x,p.sibling),L=l(p,y.children||[]),L.return=x,x=L;break e}else{a(x,p);break}else t(x,p);p=p.sibling}L=Ss(y,x.mode,L),L.return=x,x=L}return r(x);case Ma:return y=bn(y),C(x,p,y,L)}if(Co(y))return v(x,p,y,L);if(ho(y)){if(M=ho(y),typeof M!="function")throw Error(w(150));return y=M.call(y),S(x,p,y,L)}if(typeof y.then=="function")return C(x,p,lu(y),L);if(y.$$typeof===da)return C(x,p,nu(x,y),L);ou(x,y)}return typeof y=="string"&&y!==""||typeof y=="number"||typeof y=="bigint"?(y=""+y,p!==null&&p.tag===6?(a(x,p.sibling),L=l(p,y),L.return=x,x=L):(a(x,p),L=bs(y,x.mode,L),L.return=x,x=L),r(x)):a(x,p)}return function(x,p,y,L){try{Xo=0;var M=C(x,p,y,L);return Cl=null,M}catch(I){if(I===Hl||I===dd)throw I;var E=it(29,I,null,x.mode);return E.lanes=L,E.return=x,E}}}var Dn=n0(!0),l0=n0(!1),Aa=!1;function lf(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function cc(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 Pa(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Fa(e,t,a){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,(Y&2)!==0){var l=n.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),n.pending=t,t=Bu(e),$g(e,null,a),t}return ud(e,n,t,a),Bu(e)}function To(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194048)!==0)){var n=t.lanes;n&=e.pendingLanes,a|=n,t.lanes=a,Sg(e,a)}}function ws(e,t){var a=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,a===n)){var l=null,o=null;if(a=a.firstBaseUpdate,a!==null){do{var r={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};o===null?l=o=r:o=o.next=r,a=a.next}while(a!==null);o===null?l=o=t:o=o.next=t}else l=o=t;a={baseState:n.baseState,firstBaseUpdate:l,lastBaseUpdate:o,shared:n.shared,callbacks:n.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}var fc=!1;function No(){if(fc){var e=Sl;if(e!==null)throw e}}function Ro(e,t,a,n){fc=!1;var l=e.updateQueue;Aa=!1;var o=l.firstBaseUpdate,r=l.lastBaseUpdate,i=l.shared.pending;if(i!==null){l.shared.pending=null;var u=i,d=u.next;u.next=null,r===null?o=d:r.next=d,r=u;var m=e.alternate;m!==null&&(m=m.updateQueue,i=m.lastBaseUpdate,i!==r&&(i===null?m.firstBaseUpdate=d:i.next=d,m.lastBaseUpdate=u))}if(o!==null){var f=l.baseState;r=0,m=d=u=null,i=o;do{var g=i.lane&-536870913,h=g!==i.lane;if(h?(j&g)===g:(n&g)===g){g!==0&&g===Al&&(fc=!0),m!==null&&(m=m.next={lane:0,tag:i.tag,payload:i.payload,callback:null,next:null});e:{var v=e,S=i;g=t;var C=a;switch(S.tag){case 1:if(v=S.payload,typeof v=="function"){f=v.call(C,f,g);break e}f=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=S.payload,g=typeof v=="function"?v.call(C,f,g):v,g==null)break e;f=ue({},f,g);break e;case 2:Aa=!0}}g=i.callback,g!==null&&(e.flags|=64,h&&(e.flags|=8192),h=l.callbacks,h===null?l.callbacks=[g]:h.push(g))}else h={lane:g,tag:i.tag,payload:i.payload,callback:i.callback,next:null},m===null?(d=m=h,u=f):m=m.next=h,r|=g;if(i=i.next,i===null){if(i=l.shared.pending,i===null)break;h=i,i=h.next,h.next=null,l.lastBaseUpdate=h,l.shared.pending=null}}while(!0);m===null&&(u=f),l.baseState=u,l.firstBaseUpdate=d,l.lastBaseUpdate=m,o===null&&(l.shared.lanes=0),Qa|=r,e.lanes=r,e.memoizedState=f}}function o0(e,t){if(typeof e!="function")throw Error(w(191,e));e.call(t)}function r0(e,t){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;eo?o:8;var r=q.T,i={};q.T=i,yf(e,!1,t,a);try{var u=l(),d=q.S;if(d!==null&&d(i,u),u!==null&&typeof u=="object"&&typeof u.then=="function"){var m=JS(u,n);Bo(e,t,m,ft(e))}else Bo(e,t,n,ft(e))}catch(f){Bo(e,t,{then:function(){},status:"rejected",reason:f},ft())}finally{$.p=o,r!==null&&i.types!==null&&(r.types=i.types),q.T=r}}function o1(){}function xc(e,t,a,n){if(e.tag!==5)throw Error(w(476));var l=T0(e).queue;D0(e,l,t,Cn,a===null?o1:function(){return N0(e),a(n)})}function T0(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:Cn,baseState:Cn,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:xa,lastRenderedState:Cn},next:null};var a={};return t.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:xa,lastRenderedState:a},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function N0(e){var t=T0(e);t.next===null&&(t=e.alternate.memoizedState),Bo(e,t.next.queue,{},ft())}function xf(){return ze(Qo)}function R0(){return ye().memoizedState}function B0(){return ye().memoizedState}function r1(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var a=ft();e=Pa(a);var n=Fa(t,e,a);n!==null&&(We(n,t,a),To(n,t,a)),t={cache:tf()},e.payload=t;return}t=t.return}}function i1(e,t,a){var n=ft();a={lane:n,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},md(e)?O0(t,a):(a=Qc(e,t,a,n),a!==null&&(We(a,e,n),z0(a,t,n)))}function _0(e,t,a){var n=ft();Bo(e,t,a,n)}function Bo(e,t,a,n){var l={lane:n,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null};if(md(e))O0(t,l);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var r=t.lastRenderedState,i=o(r,a);if(l.hasEagerState=!0,l.eagerState=i,mt(i,r))return ud(e,t,l,0),te===null&&id(),!1}catch{}if(a=Qc(e,t,l,n),a!==null)return We(a,e,n),z0(a,t,n),!0}return!1}function yf(e,t,a,n){if(n={lane:2,revertLane:Ef(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},md(e)){if(t)throw Error(w(479))}else t=Qc(e,a,n,2),t!==null&&We(t,e,2)}function md(e){var t=e.alternate;return e===H||t!==null&&t===H}function O0(e,t){wl=Hu=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function z0(e,t,a){if((a&4194048)!==0){var n=t.lanes;n&=e.pendingLanes,a|=n,t.lanes=a,Sg(e,a)}}var Yo={readContext:ze,use:cd,useCallback:pe,useContext:pe,useEffect:pe,useImperativeHandle:pe,useLayoutEffect:pe,useInsertionEffect:pe,useMemo:pe,useReducer:pe,useRef:pe,useState:pe,useDebugValue:pe,useDeferredValue:pe,useTransition:pe,useSyncExternalStore:pe,useId:pe,useHostTransitionStatus:pe,useFormState:pe,useActionState:pe,useOptimistic:pe,useMemoCache:pe,useCacheRefresh:pe};Yo.useEffectEvent=pe;var q0={readContext:ze,use:cd,useCallback:function(e,t){return Xe().memoizedState=[e,t===void 0?null:t],e},useContext:ze,useEffect:bh,useImperativeHandle:function(e,t,a){a=a!=null?a.concat([e]):null,Lu(4194308,4,I0.bind(null,t,e),a)},useLayoutEffect:function(e,t){return Lu(4194308,4,e,t)},useInsertionEffect:function(e,t){Lu(4,2,e,t)},useMemo:function(e,t){var a=Xe();t=t===void 0?null:t;var n=e();if(Tn){Ba(!0);try{e()}finally{Ba(!1)}}return a.memoizedState=[n,t],n},useReducer:function(e,t,a){var n=Xe();if(a!==void 0){var l=a(t);if(Tn){Ba(!0);try{a(t)}finally{Ba(!1)}}}else l=t;return n.memoizedState=n.baseState=l,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:l},n.queue=e,e=e.dispatch=i1.bind(null,H,e),[n.memoizedState,e]},useRef:function(e){var t=Xe();return e={current:e},t.memoizedState=e},useState:function(e){e=hc(e);var t=e.queue,a=_0.bind(null,H,t);return t.dispatch=a,[e.memoizedState,a]},useDebugValue:hf,useDeferredValue:function(e,t){var a=Xe();return gf(a,e,t)},useTransition:function(){var e=hc(!1);return e=D0.bind(null,H,e.queue,!0,!1),Xe().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,a){var n=H,l=Xe();if(G){if(a===void 0)throw Error(w(407));a=a()}else{if(a=t(),te===null)throw Error(w(349));(j&127)!==0||c0(n,t,a)}l.memoizedState=a;var o={value:a,getSnapshot:t};return l.queue=o,bh(m0.bind(null,n,o,e),[e]),n.flags|=2048,Tl(9,{destroy:void 0},f0.bind(null,n,o,a,t),null),a},useId:function(){var e=Xe(),t=te.identifierPrefix;if(G){var a=Xt,n=Vt;a=(n&~(1<<32-ct(n)-1)).toString(32)+a,t="_"+t+"R_"+a,a=Pu++,0<\/script>",o=o.removeChild(o.firstChild);break;case"select":o=typeof n.is=="string"?r.createElement("select",{is:n.is}):r.createElement("select"),n.multiple?o.multiple=!0:n.size&&(o.size=n.size);break;default:o=typeof n.is=="string"?r.createElement(l,{is:n.is}):r.createElement(l)}}o[_e]=t,o[Je]=n;e:for(r=t.child;r!==null;){if(r.tag===5||r.tag===6)o.appendChild(r.stateNode);else if(r.tag!==4&&r.tag!==27&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break e;for(;r.sibling===null;){if(r.return===null||r.return===t)break e;r=r.return}r.sibling.return=r.return,r=r.sibling}t.stateNode=o;e:switch(qe(o,l,n),l){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}n&&na(t)}}return re(t),Ns(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,a),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==n&&na(t);else{if(typeof n!="string"&&t.stateNode===null)throw Error(w(166));if(e=Ua.current,nl(t)){if(e=t.stateNode,a=t.memoizedProps,n=null,l=Oe,l!==null)switch(l.tag){case 27:case 5:n=l.memoizedProps}e[_e]=t,e=!!(e.nodeValue===a||n!==null&&n.suppressHydrationWarning===!0||_x(e.nodeValue,a)),e||$a(t,!0)}else e=Qu(e).createTextNode(n),e[_e]=t,t.stateNode=e}return re(t),null;case 31:if(a=t.memoizedState,e===null||e.memoizedState!==null){if(n=nl(t),a!==null){if(e===null){if(!n)throw Error(w(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(w(557));e[_e]=t}else Mn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;re(t),e=!1}else a=Cs(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),e=!0;if(!e)return t.flags&256?(rt(t),t):(rt(t),null);if((t.flags&128)!==0)throw Error(w(558))}return re(t),null;case 13:if(n=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(l=nl(t),n!==null&&n.dehydrated!==null){if(e===null){if(!l)throw Error(w(318));if(l=t.memoizedState,l=l!==null?l.dehydrated:null,!l)throw Error(w(317));l[_e]=t}else Mn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;re(t),l=!1}else l=Cs(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=l),l=!0;if(!l)return t.flags&256?(rt(t),t):(rt(t),null)}return rt(t),(t.flags&128)!==0?(t.lanes=a,t):(a=n!==null,e=e!==null&&e.memoizedState!==null,a&&(n=t.child,l=null,n.alternate!==null&&n.alternate.memoizedState!==null&&n.alternate.memoizedState.cachePool!==null&&(l=n.alternate.memoizedState.cachePool.pool),o=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(o=n.memoizedState.cachePool.pool),o!==l&&(n.flags|=2048)),a!==e&&a&&(t.child.flags|=8192),ru(t,t.updateQueue),re(t),null);case 4:return kl(),e===null&&Mf(t.stateNode.containerInfo),re(t),null;case 10:return ma(t.type),re(t),null;case 19:if(Te(xe),n=t.memoizedState,n===null)return re(t),null;if(l=(t.flags&128)!==0,o=n.rendering,o===null)if(l)yo(n,!1);else{if(he!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(o=Uu(e),o!==null){for(t.flags|=128,yo(n,!1),e=o.updateQueue,t.updateQueue=e,ru(t,e),t.subtreeFlags=0,e=a,a=t.child;a!==null;)Zg(a,e),a=a.sibling;return ae(xe,xe.current&1|2),G&&ia(t,n.treeForkCount),t.child}e=e.sibling}n.tail!==null&&dt()>Vu&&(t.flags|=128,l=!0,yo(n,!1),t.lanes=4194304)}else{if(!l)if(e=Uu(o),e!==null){if(t.flags|=128,l=!0,e=e.updateQueue,t.updateQueue=e,ru(t,e),yo(n,!0),n.tail===null&&n.tailMode==="hidden"&&!o.alternate&&!G)return re(t),null}else 2*dt()-n.renderingStartTime>Vu&&a!==536870912&&(t.flags|=128,l=!0,yo(n,!1),t.lanes=4194304);n.isBackwards?(o.sibling=t.child,t.child=o):(e=n.last,e!==null?e.sibling=o:t.child=o,n.last=o)}return n.tail!==null?(e=n.tail,n.rendering=e,n.tail=e.sibling,n.renderingStartTime=dt(),e.sibling=null,a=xe.current,ae(xe,l?a&1|2:a&1),G&&ia(t,n.treeForkCount),e):(re(t),null);case 22:case 23:return rt(t),of(),n=t.memoizedState!==null,e!==null?e.memoizedState!==null!==n&&(t.flags|=8192):n&&(t.flags|=8192),n?(a&536870912)!==0&&(t.flags&128)===0&&(re(t),t.subtreeFlags&6&&(t.flags|=8192)):re(t),a=t.updateQueue,a!==null&&ru(t,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),n=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),n!==a&&(t.flags|=2048),e!==null&&Te(In),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),ma(Se),re(t),null;case 25:return null;case 30:return null}throw Error(w(156,t.tag))}function f1(e,t){switch(ef(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ma(Se),kl(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Du(t),null;case 31:if(t.memoizedState!==null){if(rt(t),t.alternate===null)throw Error(w(340));Mn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(rt(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(w(340));Mn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Te(xe),null;case 4:return kl(),null;case 10:return ma(t.type),null;case 22:case 23:return rt(t),of(),e!==null&&Te(In),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return ma(Se),null;case 25:return null;default:return null}}function Z0(e,t){switch(ef(t),t.tag){case 3:ma(Se),kl();break;case 26:case 27:case 5:Du(t);break;case 4:kl();break;case 31:t.memoizedState!==null&&rt(t);break;case 13:rt(t);break;case 19:Te(xe);break;case 10:ma(t.type);break;case 22:case 23:rt(t),of(),e!==null&&Te(In);break;case 24:ma(Se)}}function ur(e,t){try{var a=t.updateQueue,n=a!==null?a.lastEffect:null;if(n!==null){var l=n.next;a=l;do{if((a.tag&e)===e){n=void 0;var o=a.create,r=a.inst;n=o(),r.destroy=n}a=a.next}while(a!==l)}}catch(i){W(t,t.return,i)}}function Za(e,t,a){try{var n=t.updateQueue,l=n!==null?n.lastEffect:null;if(l!==null){var o=l.next;n=o;do{if((n.tag&e)===e){var r=n.inst,i=r.destroy;if(i!==void 0){r.destroy=void 0,l=t;var u=a,d=i;try{d()}catch(m){W(l,u,m)}}}n=n.next}while(n!==o)}}catch(m){W(t,t.return,m)}}function Q0(e){var t=e.updateQueue;if(t!==null){var a=e.stateNode;try{r0(t,a)}catch(n){W(e,e.return,n)}}}function W0(e,t,a){a.props=Nn(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(n){W(e,t,n)}}function _o(e,t){try{var a=e.ref;if(a!==null){switch(e.tag){case 26:case 27:case 5:var n=e.stateNode;break;case 30:n=e.stateNode;break;default:n=e.stateNode}typeof a=="function"?e.refCleanup=a(n):a.current=n}}catch(l){W(e,t,l)}}function Kt(e,t){var a=e.ref,n=e.refCleanup;if(a!==null)if(typeof n=="function")try{n()}catch(l){W(e,t,l)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(l){W(e,t,l)}else a.current=null}function J0(e){var t=e.type,a=e.memoizedProps,n=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":a.autoFocus&&n.focus();break e;case"img":a.src?n.src=a.src:a.srcSet&&(n.srcset=a.srcSet)}}catch(l){W(e,e.return,l)}}function Rs(e,t,a){try{var n=e.stateNode;N1(n,e.type,a,t),n[Je]=t}catch(l){W(e,e.return,l)}}function ex(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Ja(e.type)||e.tag===4}function Bs(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||ex(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&&Ja(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 Sc(e,t,a){var n=e.tag;if(n===5||n===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=sa));else if(n!==4&&(n===27&&Ja(e.type)&&(a=e.stateNode,t=null),e=e.child,e!==null))for(Sc(e,t,a),e=e.sibling;e!==null;)Sc(e,t,a),e=e.sibling}function Gu(e,t,a){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?a.insertBefore(e,t):a.appendChild(e);else if(n!==4&&(n===27&&Ja(e.type)&&(a=e.stateNode),e=e.child,e!==null))for(Gu(e,t,a),e=e.sibling;e!==null;)Gu(e,t,a),e=e.sibling}function tx(e){var t=e.stateNode,a=e.memoizedProps;try{for(var n=e.type,l=t.attributes;l.length;)t.removeAttributeNode(l[0]);qe(t,n,a),t[_e]=e,t[Je]=a}catch(o){W(e,e.return,o)}}var ua=!1,be=!1,_s=!1,Bh=typeof WeakSet=="function"?WeakSet:Set,Ae=null;function m1(e,t){if(e=e.containerInfo,Ac=td,e=Fg(e),$c(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var n=a.getSelection&&a.getSelection();if(n&&n.rangeCount!==0){a=n.anchorNode;var l=n.anchorOffset,o=n.focusNode;n=n.focusOffset;try{a.nodeType,o.nodeType}catch{a=null;break e}var r=0,i=-1,u=-1,d=0,m=0,f=e,g=null;t:for(;;){for(var h;f!==a||l!==0&&f.nodeType!==3||(i=r+l),f!==o||n!==0&&f.nodeType!==3||(u=r+n),f.nodeType===3&&(r+=f.nodeValue.length),(h=f.firstChild)!==null;)g=f,f=h;for(;;){if(f===e)break t;if(g===a&&++d===l&&(i=r),g===o&&++m===n&&(u=r),(h=f.nextSibling)!==null)break;f=g,g=f.parentNode}f=h}a=i===-1||u===-1?null:{start:i,end:u}}else a=null}a=a||{start:0,end:0}}else a=null;for(Dc={focusedElem:e,selectionRange:a},td=!1,Ae=t;Ae!==null;)if(t=Ae,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Ae=e;else for(;Ae!==null;){switch(t=Ae,o=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 title"))),qe(o,n,a),o[_e]=e,De(o),n=o;break e;case"link":var r=ag("link","href",l).get(n+(a.href||""));if(r){for(var i=0;iC&&(r=C,C=S,S=r);var x=oh(i,S),p=oh(i,C);if(x&&p&&(h.rangeCount!==1||h.anchorNode!==x.node||h.anchorOffset!==x.offset||h.focusNode!==p.node||h.focusOffset!==p.offset)){var y=f.createRange();y.setStart(x.node,x.offset),h.removeAllRanges(),S>C?(h.addRange(y),h.extend(p.node,p.offset)):(y.setEnd(p.node,p.offset),h.addRange(y))}}}}for(f=[],h=i;h=h.parentNode;)h.nodeType===1&&f.push({element:h,left:h.scrollLeft,top:h.scrollTop});for(typeof i.focus=="function"&&i.focus(),i=0;ia?32:a,q.T=null,a=Ic,Ic=null;var o=Ga,r=pa;if(Ie=0,Rl=Ga=null,pa=0,(Y&6)!==0)throw Error(w(331));var i=Y;if(Y|=4,fx(o.current),dx(o,o.current,r,a),Y=i,dr(0,!1),st&&typeof st.onPostCommitFiberRoot=="function")try{st.onPostCommitFiberRoot(tr,o)}catch{}return!0}finally{$.p=l,q.T=n,Ex(e,t)}}function qh(e,t,a){t=kt(a,t),t=vc(e.stateNode,t,2),e=Fa(e,t,2),e!==null&&(nr(e,2),Zt(e))}function W(e,t,a){if(e.tag===3)qh(e,e,a);else for(;t!==null;){if(t.tag===3){qh(t,e,a);break}else if(t.tag===1){var n=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(ja===null||!ja.has(n))){e=kt(a,e),a=j0(2),n=Fa(t,a,2),n!==null&&(G0(a,n,t,e),nr(n,2),Zt(n));break}}t=t.return}}function zs(e,t,a){var n=e.pingCache;if(n===null){n=e.pingCache=new g1;var l=new Set;n.set(t,l)}else l=n.get(t),l===void 0&&(l=new Set,n.set(t,l));l.has(a)||(wf=!0,l.add(a),e=b1.bind(null,e,t,a),t.then(e,e))}function b1(e,t,a){var n=e.pingCache;n!==null&&n.delete(t),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,te===e&&(j&a)===a&&(he===4||he===3&&(j&62914560)===j&&300>dt()-pd?(Y&2)===0&&Bl(e,0):If|=a,Nl===j&&(Nl=0)),Zt(e)}function Ax(e,t){t===0&&(t=Lg()),e=On(e,t),e!==null&&(nr(e,t),Zt(e))}function S1(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),Ax(e,a)}function C1(e,t){var a=0;switch(e.tag){case 31:case 13:var n=e.stateNode,l=e.memoizedState;l!==null&&(a=l.retryLane);break;case 19:n=e.stateNode;break;case 22:n=e.stateNode._retryCache;break;default:throw Error(w(314))}n!==null&&n.delete(t),Ax(e,a)}function w1(e,t){return Hc(e,t)}var Yu=null,rl=null,Ec=!1,$u=!1,qs=!1,qa=0;function Zt(e){e!==rl&&e.next===null&&(rl===null?Yu=rl=e:rl=rl.next=e),$u=!0,Ec||(Ec=!0,k1())}function dr(e,t){if(!qs&&$u){qs=!0;do for(var a=!1,n=Yu;n!==null;){if(!t)if(e!==0){var l=n.pendingLanes;if(l===0)var o=0;else{var r=n.suspendedLanes,i=n.pingedLanes;o=(1<<31-ct(42|e)+1)-1,o&=l&~(r&~i),o=o&201326741?o&201326741|1:o?o|2:0}o!==0&&(a=!0,Uh(n,o))}else o=j,o=nd(n,n===te?o:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(o&3)===0||ar(n,o)||(a=!0,Uh(n,o));n=n.next}while(a);qs=!1}}function I1(){Dx()}function Dx(){$u=Ec=!1;var e=0;qa!==0&&B1()&&(e=qa);for(var t=dt(),a=null,n=Yu;n!==null;){var l=n.next,o=Tx(n,t);o===0?(n.next=null,a===null?Yu=l:a.next=l,l===null&&(rl=a)):(a=n,(e!==0||(o&3)!==0)&&($u=!0)),n=l}Ie!==0&&Ie!==5||dr(e,!1),qa!==0&&(qa=0)}function Tx(e,t){for(var a=e.suspendedLanes,n=e.pingedLanes,l=e.expirationTimes,o=e.pendingLanes&-62914561;0i)break;var m=u.transferSize,f=u.initiatorType;m&&Xh(f)&&(u=u.responseEnd,r+=m*(u"u"?null:document;function Hx(e,t,a){var n=Fl;if(n&&typeof t=="string"&&t){var l=It(t);l='link[rel="'+e+'"][href="'+l+'"]',typeof a=="string"&&(l+='[crossorigin="'+a+'"]'),Jh.has(l)||(Jh.add(l),e={rel:e,crossOrigin:a,href:t},n.querySelector(l)===null&&(t=n.createElement("link"),qe(t,"link",e),De(t),n.head.appendChild(t)))}}function j1(e){La.D(e),Hx("dns-prefetch",e,null)}function G1(e,t){La.C(e,t),Hx("preconnect",e,t)}function V1(e,t,a){La.L(e,t,a);var n=Fl;if(n&&e&&t){var l='link[rel="preload"][as="'+It(t)+'"]';t==="image"&&a&&a.imageSrcSet?(l+='[imagesrcset="'+It(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(l+='[imagesizes="'+It(a.imageSizes)+'"]')):l+='[href="'+It(e)+'"]';var o=l;switch(t){case"style":o=_l(e);break;case"script":o=jl(e)}Dt.has(o)||(e=ue({rel:"preload",href:t==="image"&&a&&a.imageSrcSet?void 0:e,as:t},a),Dt.set(o,e),n.querySelector(l)!==null||t==="style"&&n.querySelector(sr(o))||t==="script"&&n.querySelector(cr(o))||(t=n.createElement("link"),qe(t,"link",e),De(t),n.head.appendChild(t)))}}function X1(e,t){La.m(e,t);var a=Fl;if(a&&e){var n=t&&typeof t.as=="string"?t.as:"script",l='link[rel="modulepreload"][as="'+It(n)+'"][href="'+It(e)+'"]',o=l;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":o=jl(e)}if(!Dt.has(o)&&(e=ue({rel:"modulepreload",href:e},t),Dt.set(o,e),a.querySelector(l)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(cr(o)))return}n=a.createElement("link"),qe(n,"link",e),De(n),a.head.appendChild(n)}}}function K1(e,t,a){La.S(e,t,a);var n=Fl;if(n&&e){var l=vl(n).hoistableStyles,o=_l(e);t=t||"default";var r=l.get(o);if(!r){var i={loading:0,preload:null};if(r=n.querySelector(sr(o)))i.loading=5;else{e=ue({rel:"stylesheet",href:e,"data-precedence":t},a),(a=Dt.get(o))&&Af(e,a);var u=r=n.createElement("link");De(u),qe(u,"link",e),u._p=new Promise(function(d,m){u.onload=d,u.onerror=m}),u.addEventListener("load",function(){i.loading|=1}),u.addEventListener("error",function(){i.loading|=2}),i.loading|=4,wu(r,t,n)}r={type:"stylesheet",instance:r,count:1,state:i},l.set(o,r)}}}function Y1(e,t){La.X(e,t);var a=Fl;if(a&&e){var n=vl(a).hoistableScripts,l=jl(e),o=n.get(l);o||(o=a.querySelector(cr(l)),o||(e=ue({src:e,async:!0},t),(t=Dt.get(l))&&Df(e,t),o=a.createElement("script"),De(o),qe(o,"link",e),a.head.appendChild(o)),o={type:"script",instance:o,count:1,state:null},n.set(l,o))}}function $1(e,t){La.M(e,t);var a=Fl;if(a&&e){var n=vl(a).hoistableScripts,l=jl(e),o=n.get(l);o||(o=a.querySelector(cr(l)),o||(e=ue({src:e,async:!0,type:"module"},t),(t=Dt.get(l))&&Df(e,t),o=a.createElement("script"),De(o),qe(o,"link",e),a.head.appendChild(o)),o={type:"script",instance:o,count:1,state:null},n.set(l,o))}}function eg(e,t,a,n){var l=(l=Ua.current)?Wu(l):null;if(!l)throw Error(w(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(t=_l(a.href),a=vl(l).hoistableStyles,n=a.get(t),n||(n={type:"style",instance:null,count:0,state:null},a.set(t,n)),n):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){e=_l(a.href);var o=vl(l).hoistableStyles,r=o.get(e);if(r||(l=l.ownerDocument||l,r={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},o.set(e,r),(o=l.querySelector(sr(e)))&&!o._p&&(r.instance=o,r.state.loading=5),Dt.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},Dt.set(e,a),o||Z1(l,e,a,r.state))),t&&n===null)throw Error(w(528,""));return r}if(t&&n!==null)throw Error(w(529,""));return null;case"script":return t=a.async,a=a.src,typeof a=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=jl(a),a=vl(l).hoistableScripts,n=a.get(t),n||(n={type:"script",instance:null,count:0,state:null},a.set(t,n)),n):{type:"void",instance:null,count:0,state:null};default:throw Error(w(444,e))}}function _l(e){return'href="'+It(e)+'"'}function sr(e){return'link[rel="stylesheet"]['+e+"]"}function Px(e){return ue({},e,{"data-precedence":e.precedence,precedence:null})}function Z1(e,t,a,n){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?n.loading=1:(t=e.createElement("link"),n.preload=t,t.addEventListener("load",function(){return n.loading|=1}),t.addEventListener("error",function(){return n.loading|=2}),qe(t,"link",a),De(t),e.head.appendChild(t))}function jl(e){return'[src="'+It(e)+'"]'}function cr(e){return"script[async]"+e}function tg(e,t,a){if(t.count++,t.instance===null)switch(t.type){case"style":var n=e.querySelector('style[data-href~="'+It(a.href)+'"]');if(n)return t.instance=n,De(n),n;var l=ue({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return n=(e.ownerDocument||e).createElement("style"),De(n),qe(n,"style",l),wu(n,a.precedence,e),t.instance=n;case"stylesheet":l=_l(a.href);var o=e.querySelector(sr(l));if(o)return t.state.loading|=4,t.instance=o,De(o),o;n=Px(a),(l=Dt.get(l))&&Af(n,l),o=(e.ownerDocument||e).createElement("link"),De(o);var r=o;return r._p=new Promise(function(i,u){r.onload=i,r.onerror=u}),qe(o,"link",n),t.state.loading|=4,wu(o,a.precedence,e),t.instance=o;case"script":return o=jl(a.src),(l=e.querySelector(cr(o)))?(t.instance=l,De(l),l):(n=a,(l=Dt.get(o))&&(n=ue({},a),Df(n,l)),e=e.ownerDocument||e,l=e.createElement("script"),De(l),qe(l,"link",n),e.head.appendChild(l),t.instance=l);case"void":return null;default:throw Error(w(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(n=t.instance,t.state.loading|=4,wu(n,a.precedence,e));return t.instance}function wu(e,t,a){for(var n=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),l=n.length?n[n.length-1]:null,o=l,r=0;r title"):null)}function Q1(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;return t.rel==="stylesheet"?(e=t.disabled,typeof t.precedence=="string"&&e==null):!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 Fx(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function W1(e,t,a,n){if(a.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var l=_l(n.href),o=t.querySelector(sr(l));if(o){t=o._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=Ju.bind(e),t.then(e,e)),a.state.loading|=4,a.instance=o,De(o);return}o=t.ownerDocument||t,n=Px(n),(l=Dt.get(l))&&Af(n,l),o=o.createElement("link"),De(o);var r=o;r._p=new Promise(function(i,u){r.onload=i,r.onerror=u}),qe(o,"link",n),a.instance=o}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(a,t),(t=a.state.preload)&&(a.state.loading&3)===0&&(e.count++,a=Ju.bind(e),t.addEventListener("load",a),t.addEventListener("error",a))}}var Fs=0;function J1(e,t){return e.stylesheets&&e.count===0&&ku(e,e.stylesheets),0Fs?50:800)+t);return e.unsuspend=a,function(){e.unsuspend=null,clearTimeout(n),clearTimeout(l)}}:null}function Ju(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)ku(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var ed=null;function ku(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,ed=new Map,t.forEach(eC,e),ed=null,Ju.call(e))}function eC(e,t){if(!(t.state.loading&4)){var a=ed.get(e);if(a)var n=a.get(null);else{a=new Map,ed.set(e,a);for(var l=e.querySelectorAll("link[data-precedence],style[data-precedence]"),o=0;o{"use strict";function Qx(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Qx)}catch(e){console.error(e)}}Qx(),Wx.exports=Zx()});var ty=Ft(Ld=>{"use strict";/** * @license React * react-jsx-runtime.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var uC=Symbol.for("react.transitional.element"),dC=Symbol.for("react.fragment");function ey(e,t,a){var n=null;if(a!==void 0&&(n=""+a),t.key!==void 0&&(n=""+t.key),"key"in t){a={};for(var l in t)l!=="key"&&(a[l]=t[l])}else a=t;return t=a.ref,{$$typeof:uC,type:e,key:n,ref:t!==void 0?t:null,props:a}}Ld.Fragment=dC;Ld.jsx=ey;Ld.jsxs=ey});var O=Ft((W2,ay)=>{"use strict";ay.exports=ty()});var P2={};function Me(e,t){return fetch(Ud(e),t)}async function Om(){let e=await fetch("/api/sites");Od=(await Sa(e,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0441\u0430\u0439\u0442\u044B")).sites;for(let n of[document.querySelector("#site-selector"),document.querySelector("#new-site-source")])n.replaceChildren(...Od.map(l=>{let o=document.createElement("option");return o.value=l.id,o.textContent=l.name,o.selected=l.id===s.projectConfig?.id,o}));let a=document.querySelector("#site-preview");a.href=Ud("index.html")}function eL(){return!(s.dirty||s.projectConfigDirty)||window.confirm("\u0415\u0441\u0442\u044C \u043D\u0435\u0441\u043E\u0445\u0440\u0430\u043D\u0451\u043D\u043D\u044B\u0435 \u0438\u0437\u043C\u0435\u043D\u0435\u043D\u0438\u044F. \u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043A \u0434\u0440\u0443\u0433\u043E\u043C\u0443 \u0441\u0430\u0439\u0442\u0443 \u0431\u0435\u0437 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0438\u044F?")}async function Nw(){await Om(),document.querySelector("#new-site-error").textContent="",document.querySelector("#new-site-dialog").showModal()}async function Rw(){await Om(),document.querySelector("#transfer-site-source").replaceChildren(...Od.filter(t=>t.id!==s.projectConfig.id).map(t=>{let a=document.createElement("option");return a.value=t.id,a.textContent=t.name,a})),document.querySelector("#transfer-site-error").textContent="",document.querySelector("#transfer-site-dialog").showModal()}function lo(){try{return JSON.parse(localStorage.getItem(tL)||"{}")}catch{return{}}}function Bw(e){try{localStorage.setItem(tL,JSON.stringify(e))}catch{}}function Jl(e){Bw({...lo(),...e})}function _w(){let e=lo().collections||{};return new Map(Object.entries(e).map(([t,a])=>[t,new Set(Array.isArray(a)?a:[])]))}function aL(){return String(lo().lastMediaDirectory||"").replace(/^\/+/,"")}function Ow(){let e=lo().mode;return e==="seo"||e==="knowledge"?e:"content"}function Z(e,t,a="text",n=a==="html"?"html":"text",l=null,o={}){return{path:e,label:t,kind:a,renderAs:n,group:l||gL(e),...o}}function Cm(e,t,a,n,l){return{path:e,label:t,kind:"collection",renderAs:"collection",group:a,itemTemplate:n,itemFields:l}}function D(e){c.status.textContent=e}async function Sa(e,t="\u041E\u0448\u0438\u0431\u043A\u0430 \u0437\u0430\u043F\u0440\u043E\u0441\u0430"){let a=await e.json().catch(()=>null);if(e.status===401&&a?.loginUrl)throw D("\u0421\u0435\u0441\u0441\u0438\u044F CMS \u0438\u0441\u0442\u0435\u043A\u043B\u0430. \u041E\u0442\u043A\u0440\u044B\u0432\u0430\u0435\u043C \u043F\u043E\u0432\u0442\u043E\u0440\u043D\u044B\u0439 \u0432\u0445\u043E\u0434..."),window.location.assign(a.loginUrl),new Error("\u0422\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044F \u043F\u043E\u0432\u0442\u043E\u0440\u043D\u044B\u0439 \u0432\u0445\u043E\u0434 \u0432 CMS");if(!e.ok||!a)throw new Error(a?.error||t);return a}function Ia(e,t=null){s.dirty=e,c.dirtyState.dataset.dirty=String(e),c.dirtyState.textContent=e?"\u0415\u0441\u0442\u044C \u043D\u0435\u0441\u043E\u0445\u0440\u0430\u043D\u0451\u043D\u043D\u044B\u0435 \u0438\u0437\u043C\u0435\u043D\u0435\u043D\u0438\u044F":"\u0421\u0438\u043D\u0445\u0440\u043E\u043D\u0438\u0437\u0438\u0440\u043E\u0432\u0430\u043D\u043E",t&&D(t)}function me(e=null){Ia(!0,e)}function Pw(){let e=document.createElement("input");return e.type="file",e.accept=nL,e.className="admin-file-picker-input",e.tabIndex=-1,e.setAttribute("aria-hidden","true"),document.body.append(e),e}function Gn(e){s.filePickerActive=e,e?document.body.dataset.filePickerActive="true":delete document.body.dataset.filePickerActive}function Ht(){we()&&(c.knowledgeForm.classList.add("hidden"),c.projectSettingsForm.classList.add("hidden"),c.empty.classList.add("hidden"),c.form.classList.remove("hidden"))}function at(e){return JSON.parse(JSON.stringify(e))}function Ri(e){return String(e??"").replaceAll("&","&").replaceAll("<","<").replaceAll(">",">").replaceAll('"',""").replaceAll("'","'")}function fe(e,t){return t.split(".").reduce((a,n)=>a?.[n],e)}function Rt(e,t,a){let n=t.split("."),l=n.pop(),o=e;n.forEach((r,i)=>{let u=n[i+1]??l;(o[r]==null||typeof o[r]!="object")&&(o[r]=/^\d+$/.test(u)?[]:{}),o=o[r]}),o[l]=a}function Nt(){return s.selected?.kind==="project-settings"}function Pm(){return s.projectConfig?.name||"NODE.DC"}function rL(){return s.projectConfig?.role||"\u0410\u0434\u043C\u0438\u043D\u0438\u0441\u0442\u0440\u0430\u0442\u043E\u0440 \u0441\u0430\u0439\u0442\u0430"}function km(){return s.projectConfig?.site||{ready:!1,missingFiles:[]}}function Yn(){return!!km().ready}function Fm(){c.workspaceName&&(c.workspaceName.textContent=Pm()),c.workspaceRole&&!Nt()&&(c.workspaceRole.textContent=s.mode==="knowledge"?"\u0420\u0435\u0434\u0430\u043A\u0442\u043E\u0440 \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u043E\u0432":s.mode==="seo"?"SEO-\u0440\u0435\u0436\u0438\u043C \u0441\u0430\u0439\u0442\u0430":rL())}async function Oi(){let e=await Me("/api/project/config"),t=await Sa(e,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430");return s.projectConfig=t,s.projectConfigDirty=!1,Fm(),await Om(),s.publishResumeAttempted||(s.publishResumeAttempted=!0,Qw().catch(()=>{})),t}function Fw(e){return fe(s.projectConfig||{},e)}function jw(e,t){s.projectConfig||(s.projectConfig={}),Rt(s.projectConfig,e,t),s.projectConfigDirty=!0}function iL(e){return e.type==="checkbox"?e.checked:e.type==="number"?Number(e.value||0):e.value.trim()}function Gw(){if(!(!c.projectSettingsForm||!s.projectConfig))for(let e of c.projectSettingsForm.querySelectorAll("[data-project-path]"))Rt(s.projectConfig,e.dataset.projectPath,iL(e))}async function Vw(){Gw();let e=await Me("/api/project/config",{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(s.projectConfig)}),t=await e.json().catch(()=>null);if(!e.ok||!t?.ok)throw new Error(t?.error||"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430");s.projectConfig=t.project,s.projectConfigDirty=!1,Ia(!1),Fm(),Zn(),D("\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u044B.")}async function Xw(){let[e,t,a]=await Promise.all([Me("/api/page/home"),Me("/api/knowledge"),Me("/api/media/site-size")]);if(!e.ok)throw new Error(`home.json: ${await e.text()}`);if(!t.ok)throw new Error(`knowledge.json: ${await t.text()}`);let n=a.ok?await a.json():null;D(`\u041F\u0440\u043E\u0435\u043A\u0442 \u0434\u043E\u0441\u0442\u0443\u043F\u0435\u043D. \u0420\u0430\u0437\u043C\u0435\u0440 \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E\u0433\u043E \u0441\u0430\u0439\u0442\u0430: ${n?.label||"\u043D\u0435 \u0440\u0430\u0441\u0441\u0447\u0438\u0442\u0430\u043D"}.`)}async function Kw(){let e=await Me("/api/project/publish/start",{method:"POST"}),t=await Sa(e,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u043F\u0443\u0441\u0442\u0438\u0442\u044C \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044E \u043F\u0440\u043E\u0435\u043A\u0442\u0430");if(!t?.ok||!t.job?.id)throw new Error(t?.error||"\u0421\u0435\u0440\u0432\u0435\u0440 \u043D\u0435 \u0432\u0435\u0440\u043D\u0443\u043B ID \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u0438");s.publishJob=t.job,Hd(),await cL(t.job.id)}function uL(e=s.publishJob){return!!(e&&!["completed","failed"].includes(e.state))}function dL(e){return{queued:"\u041F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F \u043F\u043E\u0441\u0442\u0430\u0432\u043B\u0435\u043D\u0430 \u0432 \u043E\u0447\u0435\u0440\u0435\u0434\u044C",scanning:"\u0421\u0447\u0438\u0442\u0430\u0435\u043C \u0444\u0430\u0439\u043B\u044B \u0438 \u043E\u0431\u0449\u0438\u0439 \u043E\u0431\u044A\u0451\u043C",connecting:"\u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0430\u0435\u043C\u0441\u044F \u043A \u0445\u043E\u0441\u0442\u0438\u043D\u0433\u0443",publishing:"\u041F\u0435\u0440\u0435\u0434\u0430\u0451\u043C \u0444\u0430\u0439\u043B\u044B \u043F\u043E SFTP",completed:"\u041F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043D\u0430",failed:"\u041F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F \u043E\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D\u0430 \u0441 \u043E\u0448\u0438\u0431\u043A\u043E\u0439"}[e?.state]||"\u041F\u043E\u0434\u0433\u043E\u0442\u0430\u0432\u043B\u0438\u0432\u0430\u0435\u043C \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044E"}function Yw(){if(!c.publish)return;let e=uL(),t=!!s.projectConfig?.deploy?.enabled;c.publish.disabled=e||!t||!Yn()||s.projectConfigDirty,c.publish.textContent=e?`${Number(s.publishJob?.percent||0).toLocaleString("ru-RU")}%`:"\u041E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u0442\u044C"}function $w(){let e=document.createElement("section");return e.className="settings-card publish-progress-card",e.dataset.publishProgress="true",e.innerHTML=`
\u041F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F

`,e}function Hd(){Yw();let e=s.publishJob;if(!e||!c.projectSettingsForm||c.projectSettingsForm.classList.contains("hidden"))return;let t=c.projectSettingsForm.querySelector("[data-publish-progress]");t||(t=$w(),c.projectSettingsForm.prepend(t));let a=Number(e.percent||0);t.dataset.state=e.state||"queued",t.querySelector("[data-publish-title]").textContent=dL(e),t.querySelector("[data-publish-percent]").textContent=`${a.toLocaleString("ru-RU")}%`,t.querySelector(".publish-progress-track").setAttribute("aria-valuenow",String(a)),t.querySelector("[data-publish-bar]").style.width=`${a}%`,t.querySelector("[data-publish-volume]").textContent=`${e.processedLabel||"0 \u0411"} \u0438\u0437 ${e.totalLabel||"0 \u0411"}`,t.querySelector("[data-publish-files]").textContent=`\u041F\u0440\u043E\u0432\u0435\u0440\u0435\u043D\u043E: ${Number(e.processedFiles||0).toLocaleString("ru-RU")}/${Number(e.totalFiles||0).toLocaleString("ru-RU")}`,t.querySelector("[data-publish-uploaded]").textContent=`\u0417\u0430\u0433\u0440\u0443\u0436\u0435\u043D\u043E: ${Number(e.uploadedFiles||0).toLocaleString("ru-RU")}`,t.querySelector("[data-publish-skipped]").textContent=`\u0411\u0435\u0437 \u0438\u0437\u043C\u0435\u043D\u0435\u043D\u0438\u0439: ${Number(e.skippedFiles||0).toLocaleString("ru-RU")}`,t.querySelector("[data-publish-current]").textContent=e.currentFile?`\u0421\u0435\u0439\u0447\u0430\u0441: ${e.currentFile}`:e.host?`${e.host}/${e.remoteRoot||""}`:"";let l=t.querySelector("[data-publish-error]");l.textContent=e.error||"",l.classList.toggle("hidden",!e.error)}function Zw(e){let t=e.currentFile?` \xB7 ${e.currentFile}`:"";return`${dL(e)}: ${Number(e.percent||0).toLocaleString("ru-RU")}% \xB7 ${e.processedLabel||"0 \u0411"}/${e.totalLabel||"0 \u0411"}${t}`}async function sL(e=""){let t=e?`?jobId=${encodeURIComponent(e)}`:"",a=await Me(`/api/project/publish/status${t}`);return a.status===404?null:(await Sa(a,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u0441\u043E\u0441\u0442\u043E\u044F\u043D\u0438\u0435 \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u0438")).job||null}async function cL(e){for(;;){let t=await sL(e);if(!t)throw new Error("\u0421\u0435\u0440\u0432\u0435\u0440 \u043F\u043E\u0442\u0435\u0440\u044F\u043B \u0441\u043E\u0441\u0442\u043E\u044F\u043D\u0438\u0435 \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u0438");if(s.publishJob=t,Hd(),D(Zw(t)),t.state==="completed")return D(jm({publish:t}).trim()||"\u041F\u0440\u043E\u0435\u043A\u0442 \u043E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u043D."),t;if(t.state==="failed")throw new Error(`\u041F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F \u043E\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D\u0430: ${t.error||"\u043D\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043D\u0430\u044F \u043E\u0448\u0438\u0431\u043A\u0430"}. \u0424\u0430\u0439\u043B: ${t.currentFile||"\u043D\u0435 \u043E\u043F\u0440\u0435\u0434\u0435\u043B\u0451\u043D"}`);await new Promise(a=>window.setTimeout(a,700))}}async function Qw(){let e=await sL();e&&(s.publishJob=e,Hd(),uL(e)?await cL(e.id):e.state==="failed"&&D(`\u041F\u043E\u0441\u043B\u0435\u0434\u043D\u044F\u044F \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043B\u0430\u0441\u044C \u0441 \u043E\u0448\u0438\u0431\u043A\u043E\u0439: ${e.error||"\u043D\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043D\u0430\u044F \u043E\u0448\u0438\u0431\u043A\u0430"}. \u0424\u0430\u0439\u043B: ${e.currentFile||"\u043D\u0435 \u043E\u043F\u0440\u0435\u0434\u0435\u043B\u0451\u043D"}`))}function jm(e){let t=e?.publish;if(!t)return"";let a=Number(t.uploadedFiles||0).toLocaleString("ru-RU"),n=Number(t.skippedFiles||0).toLocaleString("ru-RU"),l=Number(t.totalFiles||0).toLocaleString("ru-RU"),o=t.uploadedLabel||"0 \u041C\u0411";return` \u041E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u043D\u043E \u043D\u0430 ${t.host}: \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043D\u043E ${a}/${l}, \u043F\u0440\u043E\u043F\u0443\u0449\u0435\u043D\u043E ${n}, \u043E\u0431\u044A\u0435\u043C ${o}.`}function fL(){s.page&&(s.page.seo={...zw,...s.page.seo||{}})}function Ww(e){!e||Ke()||(e.seo={...Um,...e.seo||{}})}function Jw(){fL();for(let e of s.page?.regions||[])for(let t of e.blocks||[])t.seo={...Um,...t.seo||{}}}function Gm(e){if(!Yn()&&!Nt()){s.mode="content",Jl({mode:s.mode}),Fd();return}let t=e==="seo"||e==="knowledge"?e:"content";if(s.mode=t,Nt()&&(s.selected=t==="knowledge"?null:{kind:"static"}),Jl({mode:t}),t==="knowledge"&&!s.knowledge){dp().catch(a=>D(a.message)),eo();return}s.page?nt():eo()}function eo(){let e=s.mode==="seo",t=s.mode==="knowledge",a=Yn();document.body.dataset.adminMode=s.mode,c.modeNav?.classList.toggle("hidden",!a),c.modeContent&&(c.modeContent.dataset.active=String(!e&&!t)),c.modeSeo&&(c.modeSeo.dataset.active=String(e)),c.modeKnowledge&&(c.modeKnowledge.dataset.active=String(t)),c.sidebarTitle&&(c.sidebarTitle.textContent=t?"\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439":e?"SEO":"\u0410\u0434\u043C\u0438\u043D\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u0435"),c.workspaceRole&&(c.workspaceRole.textContent=t?"\u0420\u0435\u0434\u0430\u043A\u0442\u043E\u0440 \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u043E\u0432":e?"SEO-\u0440\u0435\u0436\u0438\u043C \u0441\u0430\u0439\u0442\u0430":rL()),c.editorHeading&&(c.editorHeading.textContent=t?"\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439":e?"SEO \u0441\u0430\u0439\u0442\u0430":"\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u0441\u0430\u0439\u0442\u0430"),c.panelKicker&&(c.panelKicker.textContent=t?"Knowledge":e?"SEO":"\u041A\u043E\u043D\u0442\u0435\u043D\u0442"),c.panelTitle&&(c.panelTitle.textContent=t?"\u0414\u0435\u0440\u0435\u0432\u043E \u0438 \u0441\u0442\u0430\u0442\u044C\u044F":e?"\u0421\u0435\u043C\u0430\u043D\u0442\u0438\u043A\u0430 \u0438 \u0441\u043D\u0438\u043F\u043F\u0435\u0442\u044B":"\u0420\u0435\u0434\u0430\u043A\u0442\u0438\u0440\u0443\u0435\u043C\u044B\u0435 \u043F\u043E\u043B\u044F"),c.panelNote&&(c.panelNote.textContent=t?"\u041C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u044B \u0433\u0435\u043D\u0435\u0440\u0438\u0440\u0443\u044E\u0442\u0441\u044F \u0432 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043A\u0438\u0435 SEO-\u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B \u0440\u0430\u0437\u0434\u0435\u043B\u0430 /knowledge/.":e?"\u041F\u043E\u043B\u044F \u0433\u043E\u0442\u043E\u0432\u044F\u0442 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0443 \u0438 \u0441\u0435\u043A\u0446\u0438\u0438 \u043A \u0441\u0435\u043C\u0430\u043D\u0442\u0438\u0447\u0435\u0441\u043A\u043E\u0439 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0435 \u0438 \u0434\u0430\u043B\u044C\u043D\u0435\u0439\u0448\u0435\u0439 \u0430\u0432\u0442\u043E\u043C\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438.":"\u041F\u043E\u043B\u044F \u0441\u0433\u0440\u0443\u043F\u043F\u0438\u0440\u043E\u0432\u0430\u043D\u044B \u043F\u043E \u0441\u043C\u044B\u0441\u043B\u043E\u0432\u044B\u043C \u043F\u043E\u0434\u0431\u043B\u043E\u043A\u0430\u043C \u0432\u0435\u0440\u0441\u0442\u043A\u0438."),c.addBlock&&(c.addBlock.title=t?"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0440\u0430\u0437\u0434\u0435\u043B \u0432 \u043A\u043E\u0440\u0435\u043D\u044C \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439":"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0431\u043B\u043E\u043A",c.addBlock.setAttribute("aria-label",c.addBlock.title),c.addBlock.disabled=!a),c.addProject&&(c.addProject.title="\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0441\u0430\u0439\u0442",c.addProject.setAttribute("aria-label","\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0441\u0430\u0439\u0442")),c.save&&(c.save.textContent="\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C",c.save.title=t?"\u0417\u0430\u043F\u0438\u0441\u0430\u0442\u044C \u0434\u0435\u0440\u0435\u0432\u043E \u0432 content/knowledge.json":"\u0417\u0430\u043F\u0438\u0441\u0430\u0442\u044C \u0442\u0435\u043A\u0443\u0449\u0443\u044E \u043C\u043E\u0434\u0435\u043B\u044C \u0432 content/pages/home.json",c.save.disabled=!a&&!Nt()),c.render&&(c.render.textContent=s.projectConfig?.deploy?.enabled&&s.projectConfig?.deploy?.deployOnRender?"\u0421\u043E\u0431\u0440\u0430\u0442\u044C \u0438 \u043E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u0442\u044C":"\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C \u043F\u0440\u0435\u0434\u043F\u0440\u043E\u0441\u043C\u043E\u0442\u0440",c.render.title=t?"\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u0434\u0435\u0440\u0435\u0432\u043E \u0438 \u043F\u0435\u0440\u0435\u0441\u043E\u0431\u0440\u0430\u0442\u044C \u043F\u0443\u0431\u043B\u0438\u0447\u043D\u044B\u0439 \u0440\u0430\u0437\u0434\u0435\u043B /knowledge/":"\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C \u0438 \u043F\u0435\u0440\u0435\u0441\u043E\u0431\u0440\u0430\u0442\u044C \u043F\u0443\u0431\u043B\u0438\u0447\u043D\u044B\u0439 index.html",c.render.disabled=!a&&!Nt()),c.publish&&(c.publish.classList.add("hidden"),c.publish.disabled=!0),c.reload&&(c.reload.disabled=!a&&!Nt())}function mL(e){return s.mode==="seo"&&Ke()?s.page?.seo||{}:e||{}}function e4(e){let t=new Map;for(let a of e){let n=a.group||"SEO";t.has(n)||t.set(n,[]),t.get(n).push(a)}return t}function Em(e){return e==null?"":Array.isArray(e)?e.map(Em).join(" "):typeof e=="object"?Object.values(e).map(Em).join(" "):String(e).replace(/<[^>]*>/g," ").replace(/https?:\/\/\S+/g," ").replace(/\s+/g," ").trim()}function Bd(e,t,a){let n=String(e||"").trim().length;return!t&&!a?{status:"info",text:n?`${n} \u0441\u0438\u043C\u0432.`:"\u043F\u0443\u0441\u0442\u043E"}:n?t&&na?{status:"warn",text:`${n} \u0441\u0438\u043C\u0432. \xB7 \u0446\u0435\u043B\u044C ${t||0}-${a||"\u221E"}`}:{status:"good",text:`${n} \u0441\u0438\u043C\u0432.`}:{status:"bad",text:`\u043F\u0443\u0441\u0442\u043E \xB7 \u0446\u0435\u043B\u044C ${t||0}-${a||"\u221E"}`}}function mn(e,t,a="info"){let n=document.createElement("div"),l=document.createElement("span"),o=document.createElement("strong");return n.className="seo-metric",n.dataset.status=a,l.textContent=e,o.textContent=t,n.append(l,o),n}function t4(e){let t=Em(e?.content||""),a=t?t.split(/\s+/).filter(Boolean).length:0;return{text:t,words:a,chars:t.length}}function a4({targetModel:e,fields:t,isStatic:a}){let n=document.createElement("section"),l=document.createElement("div"),o=document.createElement("h3"),r=document.createElement("p"),i=document.createElement("div");if(n.className="seo-diagnostics",l.className="group-head",o.textContent=a?"\u0414\u0438\u0430\u0433\u043D\u043E\u0441\u0442\u0438\u043A\u0430 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B":"\u0414\u0438\u0430\u0433\u043D\u043E\u0441\u0442\u0438\u043A\u0430 \u0431\u043B\u043E\u043A\u0430",r.className="group-desc",r.textContent=a?"\u0411\u0430\u0437\u043E\u0432\u044B\u0435 \u043F\u043E\u043B\u044F, \u043A\u043E\u0442\u043E\u0440\u044B\u0435 \u043F\u043E\u043F\u0430\u0434\u0430\u044E\u0442 \u0432 head, Open Graph, sitemap \u0438 structured data.":"\u0427\u0435\u0440\u043D\u043E\u0432\u043E\u0439 \u0441\u043B\u043E\u0439 \u0434\u043B\u044F \u0441\u0435\u043C\u0430\u043D\u0442\u0438\u043A\u0438 \u0431\u043B\u043E\u043A\u0430. \u041F\u043E\u0437\u0436\u0435 \u0435\u0433\u043E \u0441\u043C\u043E\u0436\u0435\u0442 \u0437\u0430\u043F\u043E\u043B\u043D\u044F\u0442\u044C \u0432\u043D\u0435\u0448\u043D\u0438\u0439 SEO-\u043C\u043E\u0434\u0443\u043B\u044C.",l.append(o,r),i.className="seo-metric-grid",a){let u=Bd(fe(e,"seo.title"),35,70),d=Bd(fe(e,"seo.description"),110,170),m=String(fe(e,"seo.canonicalUrl")||""),f=String(fe(e,"seo.ogImage")||"");i.append(mn("Title",u.text,u.status),mn("Description",d.text,d.status),mn("Canonical",m.startsWith("https://")?"\u0430\u0431\u0441\u043E\u043B\u044E\u0442\u043D\u044B\u0439":"\u043F\u0440\u043E\u0432\u0435\u0440\u0438\u0442\u044C",m.startsWith("https://")?"good":"warn"),mn("OG image",f?"\u0437\u0430\u0434\u0430\u043D":"\u043F\u0443\u0441\u0442\u043E",f?"good":"bad"))}else{let u=t4(e),d=String(fe(e,"seo.primaryQuery")||"").trim(),m=String(fe(e,"seo.secondaryQueries")||"").split(/\n|,/).map(g=>g.trim()).filter(Boolean),f=Bd(fe(e,"seo.title"),35,80);i.append(mn("\u0422\u0435\u043A\u0441\u0442 \u0431\u043B\u043E\u043A\u0430",`${u.words} \u0441\u043B\u043E\u0432`,u.words>=40?"good":"warn"),mn("\u041E\u0441\u043D\u043E\u0432\u043D\u043E\u0439 \u0437\u0430\u043F\u0440\u043E\u0441",d?"\u0437\u0430\u0434\u0430\u043D":"\u043F\u0443\u0441\u0442\u043E",d?"good":"bad"),mn("\u0421\u043C\u0435\u0436\u043D\u044B\u0435 \u0437\u0430\u043F\u0440\u043E\u0441\u044B",`${m.length}`,m.length?"good":"warn"),mn("SEO-\u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A",f.text,f.status))}return n.append(l,i),n}function Pv(e,t,a){if(!e)return;let n=Bd(Vd(t),a.min,a.max);e.dataset.status=n.status,e.textContent=n.text}function n4({targetModel:e,seoField:t,grid:a}){let n=document.createElement("label"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=t.kind==="textarea",d=t.kind==="select"?document.createElement("select"):u?document.createElement("textarea"):document.createElement("input"),m=fe(e,t.path)??"",f=t.min||t.max?document.createElement("span"):null;if(n.className=`field-control seo-field${u?" wide":""}`,l.className="field-label-row",o.className="field-label-text",o.textContent=t.label||t.path,r.className="field-kind",r.textContent=t.kind||"text",i.className="field-path",i.textContent=t.path,l.append(o,r),t.kind==="select"){let g=new Set([...t.options||[],m].filter(Boolean));for(let h of g){let v=document.createElement("option");v.value=h,v.textContent=h,d.append(v)}}else u||(d.autocomplete="off",d.type=t.kind==="url"?"url":"text");d.dataset.seoPath=t.path,d.value=m,d.placeholder=t.placeholder||"",Pv(f,d,t),d.addEventListener(t.kind==="select"?"change":"input",()=>{Rt(e,t.path,Vd(d)),Pv(f,d,t),c.json.value=JSON.stringify(mL(we()),null,2),me("SEO-\u043F\u043E\u043B\u044F \u043E\u0431\u043D\u043E\u0432\u043B\u0435\u043D\u044B \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB \u0438\u043B\u0438 \xAB\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C index.html\xBB.")}),n.append(l,d),f&&(f.className="seo-field-meter",n.append(f)),n.append(i),a.append(n)}function l4(e){let t=Ke(),a=t?s.page:e,n=t?qw:Uw;t?fL():Ww(e),c.contentFields.innerHTML="",c.contentFields.append(a4({targetModel:a,fields:n,isStatic:t}));for(let[l,o]of e4(n)){let r=document.createElement("section"),i=document.createElement("div"),u=document.createElement("div"),d=document.createElement("h3"),m=document.createElement("p"),f=document.createElement("div");r.className="content-group seo-group",i.className="group-head",d.textContent=l,m.className="group-desc",m.textContent=t?"\u041F\u043E\u043B\u044F \u0443\u0440\u043E\u0432\u043D\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B \u0438 \u043F\u043E\u0438\u0441\u043A\u043E\u0432\u043E\u0433\u043E \u0441\u043D\u0438\u043F\u043F\u0435\u0442\u0430.":"\u041F\u043E\u043B\u044F \u0443\u0440\u043E\u0432\u043D\u044F \u0441\u0435\u043A\u0446\u0438\u0438 \u0434\u043B\u044F \u0431\u0443\u0434\u0443\u0449\u0435\u0439 \u0441\u0435\u043C\u0430\u043D\u0442\u0438\u0447\u0435\u0441\u043A\u043E\u0439 \u043A\u0430\u0440\u0442\u044B.",u.append(d,m),i.append(u),f.className="group-grid";for(let g of o)n4({targetModel:a,seoField:g,grid:f});r.append(i,f),c.contentFields.append(r)}}function pL(e){return o4.has(String(e||"").trim())}function Mm(e){return/^(https?:)?\/\//i.test(String(e||""))||/^(mailto:|tel:)/i.test(String(e||""))}function Pd(e){let t=String(e||"").trim();if(!t||/^javascript:/i.test(t)||Mm(t))return"";let a=t;return a.includes("#")&&(a=a.slice(a.indexOf("#")+1)),a=a.replace(/^\/+/,"").replace(/^index\.html#?/i,"").replace(/^#+/,"").trim(),!a||a==="/"||a==="index.html"||a.startsWith("knowledge/")||pL(a)?"":a}function Vn(){let e=[];for(let t of s.page?.regions||[])for(let a of t.blocks||[]){if(a.enabled===!1)continue;let n=Pd(a.anchor);n&&e.push({block:a,id:a.id,label:a.adminLabel||a.id,target:n})}return e.sort((t,a)=>t.target.localeCompare(a.target,"ru"))}function r4(e){let t=String(e||"").trim(),a=Pd(t),n=t.toLowerCase(),l=a.toLowerCase();return Vn().find(o=>o.target.toLowerCase()===l)||Vn().find(o=>o.id.toLowerCase()===n)||Vn().find(o=>o.label.toLowerCase()===n)||null}function Vm(e,t=null){let a=new Set(Vn().filter(r=>r.block!==t).map(r=>r.target)),n=Km(Pd(e)||e||"section"),l=n,o=2;for(;a.has(l);)l=`${n}-${o}`,o+=1;return l}function hL(){let e=new Map,t=[];for(let a of Vn()){if(e.has(a.target)){t.push({target:a.target,first:e.get(a.target),second:a});continue}e.set(a.target,a)}return t}function i4(){let e=hL();if(!e.length)return;let t=e.map(({target:a,first:n,second:l})=>`${a}: ${n.label} / ${l.label}`).join("; ");throw new Error(`Target \u0434\u043E\u043B\u0436\u0435\u043D \u0431\u044B\u0442\u044C \u0443\u043D\u0438\u043A\u0430\u043B\u044C\u043D\u044B\u043C \u0434\u043B\u044F \u043A\u0430\u0436\u0434\u043E\u0433\u043E \u0431\u043B\u043E\u043A\u0430. \u0414\u0443\u0431\u043B\u0438: ${t}`)}function Am(){if(c.targetOptions){c.targetOptions.innerHTML="";for(let{target:e,label:t}of Vn()){let a=document.createElement("option");a.value=e,a.label=t,c.targetOptions.append(a)}}}function u4(e,t={}){if(!e||typeof e!="object")return;let a=e.href??t.href??"",n=e.target??t.target??"",l=e.linkTarget??t.linkTarget??"";pL(n)&&(l||=n,n="");let o=Mm(a)?"href":"target",r=e.linkMode==="href"||e.linkMode==="target"?e.linkMode:o;r==="target"&&!n&&a&&!Mm(a)&&(n=a,a=""),e.enabled=e.enabled!==!1,e.href=a,e.target=n,e.linkMode=r,e.linkTarget=l}function d4(e,t=[]){Array.isArray(e)&&e.forEach((a,n)=>u4(a,t[n]||t[0]||{}))}function gL(e){return e.startsWith("content.navigation.")?"\u0428\u0430\u043F\u043A\u0430":e.startsWith("content.notifications.")?"\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F":e.startsWith("content.dock.")?"Dock":e.startsWith("content.assets.")?"\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B":e.startsWith("content.cards.")?"\u0422\u0435\u0437\u0438\u0441\u044B \u043F\u0435\u0440\u0432\u043E\u0433\u043E \u044D\u043A\u0440\u0430\u043D\u0430":e.startsWith("content.app.")||e.startsWith("content.accessCard.")?"\u041A\u0430\u0440\u0442\u043E\u0447\u043A\u0430 \u0434\u043E\u0441\u0442\u0443\u043F\u0430":e.startsWith("content.form.")?"\u0424\u043E\u0440\u043C\u0430":e==="content.legalHtml"||e.startsWith("content.legal.")?"\u042E\u0440\u0438\u0434\u0438\u0447\u0435\u0441\u043A\u0438\u0439 \u0431\u043B\u043E\u043A":e==="content.windowTitle"||e==="content.videoSrc"?"\u0412\u0438\u0434\u0435\u043E-\u043E\u043A\u043D\u043E":e.startsWith("content.features.")?"\u041F\u0443\u043D\u043A\u0442\u044B":e.startsWith("content.scroll.")?"\u0421\u043A\u0440\u043E\u043B\u043B":e.startsWith("content.sliderItems.")?"\u0421\u043B\u0430\u0439\u0434\u0435\u0440":e.startsWith("content.bottomInfo.")?"\u041D\u0438\u0436\u043D\u0438\u0439 \u0438\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0438\u043E\u043D\u043D\u044B\u0439 \u0431\u043B\u043E\u043A":e.startsWith("content.oneClick.")?"\u041E\u0434\u0438\u043D \u043A\u043B\u0438\u043A":e.startsWith("content.mcp.")?"MCP":e.startsWith("content.faq.")?"FAQ":e.startsWith("content.cta.")?"CTA":e.startsWith("content.plans.")||e.startsWith("content.pricing.")?"\u0422\u0430\u0440\u0438\u0444\u044B":e.startsWith("content.pricingCells.")?"\u0421\u0442\u0440\u043E\u043A\u0438 \u0442\u0430\u0440\u0438\u0444\u043E\u0432":e==="content.galleryItems"||e.startsWith("content.galleryItems.")?"\u041A\u0430\u0440\u0442\u043E\u0447\u043A\u0438 \u0441\u043A\u0440\u0438\u043D\u0448\u043E\u0442\u043E\u0432":e==="content.filesEnabled"||e.startsWith("content.files.")?"TXT-\u0444\u0430\u0439\u043B\u044B":e==="content.footer.policyEnabled"||e==="content.footer.policyHtml"?"\u041F\u043E\u043B\u0438\u0442\u0438\u043A\u0438":e.startsWith("content.footer.navLinks.")?"\u041D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044F \u0444\u0443\u0442\u0435\u0440\u0430":e.startsWith("content.footer.contactLinks.")?"\u041A\u043E\u043D\u0442\u0430\u043A\u0442\u043D\u044B\u0435 \u0441\u0441\u044B\u043B\u043A\u0438":e.startsWith("content.footer.")?"\u0424\u0443\u0442\u0435\u0440":e.startsWith("content.heading.")||e==="content.introHtml"?"\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A":"\u041A\u043E\u043D\u0442\u0435\u043D\u0442"}function s4(e={},t={}){return[{enabled:!0,title:"NODE.DC",href:"javascript:void(0)",linkTarget:"",targetId:e.appTarget||"app-data",iconSrc:t.appIconSrc||Ne.content.assets.appIconSrc,iconAlt:t.appIconAlt||Ne.content.assets.appIconAlt,className:"dock-icon nodedc-app",iconClass:"logo",dividerBefore:!1},{enabled:!0,title:"\u041A\u043E\u0440\u0437\u0438\u043D\u0430",href:"javascript:void(0)",linkTarget:"",targetId:"",iconSrc:"./assets/site/images/69a9ae818a76c773dc3cf7bc_trash.avif",iconAlt:e.trashAlt||"\u0411\u0435\u043B\u0430\u044F \u0438\u043A\u043E\u043D\u043A\u0430 \u043A\u043E\u0440\u0437\u0438\u043D\u044B.",className:"dock-icon no-bg",iconClass:"dock-app-img trash",dividerBefore:!0}]}function c4(e,t={}){let a=s4(e,t);Array.isArray(e.items)?e.items=e.items.map((n,l)=>{let o=a[l]||a[0],r=i=>Object.prototype.hasOwnProperty.call(n,i);return{enabled:n.enabled!==!1,title:n.title||o.title||`\u042D\u043B\u0435\u043C\u0435\u043D\u0442 ${l+1}`,href:n.href??o.href??"",linkTarget:n.linkTarget??o.linkTarget??"",targetId:n.targetId??o.targetId??"",iconSrc:r("iconSrc")?n.iconSrc:o.iconSrc,iconAlt:r("iconAlt")?n.iconAlt:n.alt||o.iconAlt,className:n.className||o.className||"dock-icon nodedc-app",iconClass:r("iconClass")?n.iconClass:o.iconClass||"logo",dividerBefore:!!n.dividerBefore}}):e.items=a,e.demoFileLabel||=Ne.content.dock.demoFileLabel,delete e.appTarget,delete e.trashAlt}function f4(){if(!s.page.staticElements){s.page.staticElements=at(Ne);return}s.page.staticElements.id||=Ne.id,s.page.staticElements.type||=Ne.type,s.page.staticElements.adminLabel||=Ne.adminLabel,s.page.staticElements.enabled=!0,s.page.staticElements.content||=at(Ne.content),s.page.staticElements.content.navigation||=at(Ne.content.navigation),s.page.staticElements.content.navigation.logoSrc||=Ne.content.navigation.logoSrc,s.page.staticElements.content.navigation.links||=at(Ne.content.navigation.links),d4(s.page.staticElements.content.navigation.links,Ne.content.navigation.links),s.page.staticElements.content.notifications||=at(Ne.content.notifications),s.page.staticElements.content.notifications.forEach((e,t)=>{e.enabled=e.enabled!==!1,e.eyebrowClass||=Ne.content.notifications[t]?.eyebrowClass||"red-txt gray"}),s.page.staticElements.content.assets||=at(Ne.content.assets);for(let[e,t]of Object.entries(Ne.content.assets))Object.prototype.hasOwnProperty.call(s.page.staticElements.content.assets,e)||(s.page.staticElements.content.assets[e]=t);s.page.staticElements.content.dock||=at(Ne.content.dock),c4(s.page.staticElements.content.dock,s.page.staticElements.content.assets),s.page.staticElements.editableFields=at(Ne.editableFields)}function m4(){let t=(Array.isArray(s.page.regions)?s.page.regions:[]).flatMap(a=>(a.blocks??[]).map(n=>(n.region||=a.id,n)));s.page.regions=[{id:zm,label:qm,description:"\u0415\u0434\u0438\u043D\u044B\u0439 \u043F\u043E\u0440\u044F\u0434\u043E\u043A \u0441\u0435\u043A\u0446\u0438\u0439 \u0433\u043B\u0430\u0432\u043D\u043E\u0439 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B.",blocks:t}]}function p4(){return Math.max(0,s.page.regions.findIndex(e=>e.id===zm))}function Ke(){return s.selected?.kind==="static"}function $n(){return s.selected?Ke()?{id:"static",label:"\u0421\u0442\u0430\u0442\u0438\u0447\u043D\u044B\u0435 \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",description:"Shell-\u0441\u043B\u043E\u0439 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B: \u0448\u0430\u043F\u043A\u0430, \u0443\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F, dock \u0438 \u0431\u0430\u0437\u043E\u0432\u044B\u0435 \u0430\u0441\u0441\u0435\u0442\u044B."}:s.page.regions[s.selected.regionIndex]:null}function we(){if(!s.selected)return null;if(Ke())return s.page.staticElements;let e=$n();return!e||s.selected.blockIndex==null?null:e.blocks[s.selected.blockIndex]}function Xm(e){let t=new Set([s.page.staticElements?.id,...s.page.regions.flatMap(l=>l.blocks.map(o=>o.id))]),a=`${e}-copy`,n=2;for(;t.has(a);)a=`${e}-copy-${n}`,n+=1;return a}function h4(e){return Xm(Km(e||"block").replace(/-copy(?:-\d+)?$/,""))}function zi(e,t=22){return e?e.length>t?`${e.slice(0,t-1)}\u2026`:e:""}function Ca(e){if(!e)return"\u0424\u0430\u0439\u043B \u043D\u0435 \u0432\u044B\u0431\u0440\u0430\u043D";try{let t=e.split("?")[0].split("#")[0];return decodeURIComponent(t.slice(t.lastIndexOf("/")+1))||e}catch{return e}}function Km(e){return String(e||"site").normalize("NFKD").replace(/[^\w.-]+/g,"-").replace(/^-+|-+$/g,"").toLowerCase()||"site"}function Bi(e){return e?/^(blob:|data:|https?:)/i.test(e)?e:Ud(e):""}function g4(e){return e?/\.(mp4|webm|mov|m4v|avi|mkv)(\?.*)?$/i.test(e)?"video":/\.(png|jpe?g|gif|svg|ico|avif|webp)(\?.*)?$/i.test(e)?"image":/\.(glb|gltf)(\?.*)?$/i.test(e)?"model":/\.(woff2?|ttf|otf)(\?.*)?$/i.test(e)?"font":null:null}function xL(e){let t=Number(e);if(!Number.isFinite(t)||t<0)return"";if(t<1024)return`${t} B`;let a=["KB","MB","GB"],n=t/1024,l=0;for(;n>=1024&&l=10?n.toFixed(0):n.toFixed(1)} ${a[l]}`}function Fv(e){let t=Number(e);return Number.isFinite(t)?new Intl.DateTimeFormat("ru-RU",{day:"2-digit",month:"2-digit",year:"2-digit",hour:"2-digit",minute:"2-digit"}).format(new Date(t)):""}function Ym(e){return e?.usage?.status||"unused"}function zd(e){return e?.usage?.label||"\u041D\u0435 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u0435\u0442\u0441\u044F"}function jv(e){return[e.kind,e.extension,xL(e.size)].filter(Boolean).join(" \xB7 ")}function qi(){let e=s.mediaLibrary.selectedEntry;return e?.type==="file"?e:null}function x4(e){let t=String(e?.path||"").toLowerCase(),a=String(e?.label||"").toLowerCase();return/logo|icon|wordmark|логотип|икон/.test(`${t} ${a}`)}function $m(e,t){let a=t.path.toLowerCase(),n=String(fe(e,t.path)??"").toLowerCase(),l=Km(e?.id||e?.type||"site"),o="images";return(a.includes("webgl")||n.endsWith(".glb")||n.endsWith(".gltf"))&&(o="models"),(a.includes("video")||a.includes("media")||a.includes("sliders")||a.includes("slideritems"))&&(o="media"),(a.includes("font")||/\.(woff2?|ttf|otf)(\?.*)?$/i.test(n))&&(o="fonts"),a.includes("favicon")?"favicon":`${o}/${l}`}function yL(e){let t=e.id||"",a=e.type||"";return t==="static-elements"?"SE":t.includes("gallery")||t.includes("screenshot")?"SC":t.includes("hero")?"H":t.includes("feature")||t.includes("video")?"V":t.includes("component")?"C":t.includes("modes")?"AI":t.includes("faq")?"Q":t.includes("pricing")?"P":t.includes("waitlist")?"W":t.includes("footer")?"F":a.includes("Cta")?"GO":"B"}function y4(e){return e.id===zm||e.id==="beforeCViz"||e.id==="cViz"?qm:e.label||e.id}function vL(e){return e.template||e.type||e.id}function ba(){s.drag=null,s.dragTarget=null,document.querySelectorAll(".dragging, .drag-over, .sorting-source, .sorting-active").forEach(e=>{e.classList.remove("dragging","drag-over","sorting-source","sorting-active")}),document.querySelectorAll(".sortable-ghost, .sortable-placeholder").forEach(e=>e.remove())}function LL(e,t){let a=e.getBoundingClientRect(),n=e.cloneNode(!0);return n.classList.add("sortable-ghost"),n.style.width=`${a.width}px`,n.style.height=`${a.height}px`,n.dataset.dragOffsetX=String(t.clientX-a.left),n.dataset.dragOffsetY=String(t.clientY-a.top),document.body.append(n),Zm(n,t),n}function Zm(e,t){e.style.left=`${t.clientX-Number(e.dataset.dragOffsetX||0)}px`,e.style.top=`${t.clientY-Number(e.dataset.dragOffsetY||0)}px`}function bL(e){let t=e.getBoundingClientRect(),a=document.createElement("div");return a.className="sortable-placeholder",a.style.height=`${t.height}px`,a}function v4(e,t){return e.clientX>=t.left&&e.clientX<=t.right&&e.clientY>=t.top&&e.clientY<=t.bottom}function SL({event:e,list:t,source:a,placeholder:n,selector:l}){let o=t.getBoundingClientRect();if(!v4(e,o))return;let r=[...t.querySelectorAll(l)].filter(i=>i!==a&&i!==n);for(let i of r){let u=i.getBoundingClientRect();if(e.clientYl===t||l!==a).indexOf(t)}function L4(e,t,a){let n=s.page.regions[e];if(!n||t===a||a<0){ba();return}let[l]=n.blocks.splice(t,1);n.blocks.splice(Math.min(a,n.blocks.length),0,l),s.selected={kind:"block",regionIndex:e,blockIndex:Math.min(a,n.blocks.length-1)},ba(),nt(),me("\u041F\u043E\u0440\u044F\u0434\u043E\u043A \u0431\u043B\u043E\u043A\u043E\u0432 \u0438\u0437\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB \u0438\u043B\u0438 \xAB\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C index.html\xBB.")}function b4(e,t,a){if(e.button!==0)return;e.preventDefault(),e.stopPropagation();let n=t.closest(".block-list");if(!n)return;let l=bL(t),o=LL(t,e);s.drag=a,s.dragTarget=a,t.classList.add("dragging","sorting-source"),n.classList.add("sorting-active"),t.after(l);let r=d=>{Zm(o,d),SL({event:d,list:n,source:t,placeholder:l,selector:".block-btn.has-drag-handle"})},i=()=>{document.removeEventListener("pointermove",r),document.removeEventListener("pointerup",i),document.removeEventListener("pointercancel",u);let d=CL({list:n,placeholder:l,source:t,selector:".block-btn.has-drag-handle"});L4(a.regionIndex,a.blockIndex,d)},u=()=>{document.removeEventListener("pointermove",r),document.removeEventListener("pointerup",i),document.removeEventListener("pointercancel",u),ba()};document.addEventListener("pointermove",r),document.addEventListener("pointerup",i),document.addEventListener("pointercancel",u)}function S4(e,t){if(!e||e.regionIndex!==t.regionIndex||e.blockIndex===t.blockIndex){ba();return}let a=s.page.regions[e.regionIndex];if(!a){ba();return}let[n]=a.blocks.splice(e.blockIndex,1),l=t.blockIndex;e.blockIndexv.stopPropagation()),h.addEventListener("pointerdown",v=>b4(v,i,r)),h.addEventListener("dragstart",v=>{s.drag=r,i.classList.add("dragging"),v.dataTransfer.effectAllowed="move",v.dataTransfer.setData("text/plain",`${r.regionIndex}:${r.blockIndex}`)}),h.addEventListener("dragend",ba),h.addEventListener("keydown",v=>v.stopPropagation()),i.append(h)}g&&(i.addEventListener("dragover",h=>{!s.drag||s.drag.regionIndex!==r.regionIndex||(h.preventDefault(),h.dataTransfer.dropEffect="move",i.classList.add("drag-over"))}),i.addEventListener("dragleave",()=>i.classList.remove("drag-over")),i.addEventListener("drop",h=>{h.preventDefault(),i.classList.remove("drag-over"),S4(s.drag,r)})),i.addEventListener("click",o),i.addEventListener("keydown",h=>{h.key!=="Enter"&&h.key!==" "||(h.preventDefault(),o(h))}),e.append(i)}function Dm(){c.regions.innerHTML="";let e=document.createElement("section"),t=document.createElement("h3"),a=document.createElement("div");t.className="region-title",t.textContent="Static",a.className="block-list",Gv({list:a,block:s.page.staticElements,meta:"shell \xB7 nav \xB7 notifications \xB7 dock",active:Ke(),disabled:!1,onClick:()=>{s.selected={kind:"static"},nt()}}),e.append(t,a),c.regions.append(e),s.page.regions.forEach((n,l)=>{let o=document.createElement("section"),r=document.createElement("h3"),i=document.createElement("div");r.className="region-title",r.textContent=y4(n),i.className="block-list",n.blocks.forEach((u,d)=>{let m=s.selected?.kind==="block"&&s.selected?.regionIndex===l&&s.selected?.blockIndex===d;Gv({list:i,block:u,meta:vL(u),active:m,disabled:u.enabled===!1,dragContext:{regionIndex:l,blockIndex:d},onClick:()=>{s.selected={kind:"block",regionIndex:l,blockIndex:d},nt()}})}),o.append(r,i),c.regions.append(o)})}function wL(){let e=p4();return s.templates.map(t=>({...t,regionIndex:e,regionLabel:qm}))}function C4(){c.templateList.innerHTML="";for(let e of wL()){let t=document.createElement("button"),a=document.createElement("span"),n=document.createElement("span"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span");t.type="button",t.className="template-card",a.className="template-card-icon",a.textContent=yL(e.block),n.className="template-card-copy",l.className="template-card-title",l.textContent=e.block.adminLabel||e.block.id,o.className="template-card-meta",o.textContent=vL(e.block),r.className="template-card-region",r.textContent=`\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u0441\u044F \u0432: ${e.regionLabel}`,n.append(l,o,r),t.append(a,n),t.addEventListener("click",()=>I4(e.key)),c.templateList.append(t)}}function w4(){C4(),c.templateModal.classList.remove("hidden"),c.templateList.querySelector("button")?.focus()}function Ui(){c.templateModal.classList.add("hidden"),c.addBlock?.focus()}function to(e=!1){let t=s.deleteConfirmResolve;s.deleteConfirmResolve=null,c.deleteModal.classList.add("hidden"),t&&t(e)}function oo({title:e="\u041F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435",body:t="\u0412\u044B \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043B\u044C\u043D\u043E \u043F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044C \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u0435 \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430?"}={}){return s.deleteConfirmResolve&&to(!1),new Promise(a=>{s.deleteConfirmResolve=a,c.deleteModalTitle.textContent=e,c.deleteModalBody.textContent=t,c.deleteModal.classList.remove("hidden"),c.deleteModalConfirm.focus()})}function ao(e=null){let t=s.mediaActionResolve;s.mediaActionResolve=null,c.mediaActionModal.classList.add("hidden"),t&&t(e)}function IL({title:e="\u0414\u0435\u0439\u0441\u0442\u0432\u0438\u0435",body:t="\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u0438\u043C\u044F.",label:a="\u0418\u043C\u044F",value:n="",confirmLabel:l="\u041F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044C"}={}){return s.mediaActionResolve&&ao(null),new Promise(o=>{s.mediaActionResolve=o,c.mediaActionTitle.textContent=e,c.mediaActionBody.textContent=t,c.mediaActionLabel.textContent=a,c.mediaActionConfirm.textContent=l,c.mediaActionInput.value=n,c.mediaActionModal.classList.remove("hidden"),c.mediaActionInput.focus(),c.mediaActionInput.select()})}function I4(e){let t=wL().find(l=>l.key===e);if(!t)return;let a=s.page.regions[t.regionIndex],n=at(t.block);n.id=h4(n.id),n.enabled=!0,n.anchor&&(n.anchor=Vm(n.anchor||n.adminLabel||n.id,n)),n.scopeIds=!0,n.seo={...Um,...n.seo||{}},a.blocks.push(n),s.selected={kind:"block",regionIndex:t.regionIndex,blockIndex:a.blocks.length-1},Ui(),nt(),me(`\u0414\u043E\u0431\u0430\u0432\u043B\u0435\u043D \u0431\u043B\u043E\u043A \xAB${n.adminLabel||n.id}\xBB. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB \u0438\u043B\u0438 \xAB\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C index.html\xBB.`)}function k4(e){for(let t of[c.moveUp,c.moveDown,c.duplicate,c.copy,c.pasteAfter,c.deleteBlock])t.disabled=e}function E4(e){console.error(e),c.knowledgeForm.classList.add("hidden"),c.projectSettingsForm.classList.add("hidden"),c.empty.classList.add("hidden"),c.form.classList.remove("hidden"),c.contentFields.innerHTML="";let t=document.createElement("div");t.className="empty-note editor-error-note",t.textContent=`\u0420\u0435\u0434\u0430\u043A\u0442\u043E\u0440 \u043D\u0435 \u0441\u043C\u043E\u0433 \u043E\u0442\u0440\u0438\u0441\u043E\u0432\u0430\u0442\u044C \u043F\u043E\u043B\u044F \u0431\u043B\u043E\u043A\u0430: ${e.message}`,c.contentFields.append(t),D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0435\u0434\u0430\u043A\u0442\u043E\u0440\u0430: ${e.message}`)}function Wt({path:e,label:t,type:a="text",placeholder:n="",options:l=[],hint:o=""}){let r=document.createElement("label"),i=document.createElement("span"),u=document.createElement("span"),d=l.length?document.createElement("select"):document.createElement("input"),m=Fw(e),f=a==="password";if(r.className=a==="checkbox"?"toggle-row":"field-control",i.textContent=t,a==="checkbox")d.type="checkbox",d.checked=!!m,r.append(d,i);else{if(l.length){for(let h of l){let v=document.createElement("option");v.value=h,v.textContent=h,d.append(v)}d.value=m||l[0]||""}else d.type=a,d.value=m??"",d.placeholder=n;if(u.className="field-kind",u.textContent=l.length?"SELECT":a==="number"?"NUMBER":f?"SECRET":"TEXT",r.append(i,u),f){let h=document.createElement("span"),v=document.createElement("button");h.className="secret-input-wrap",v.className="secret-toggle-button",v.type="button",v.innerHTML='',v.setAttribute("aria-label","\u041F\u043E\u043A\u0430\u0437\u0430\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"),v.title="\u041F\u043E\u043A\u0430\u0437\u0430\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435",v.addEventListener("click",()=>{let S=d.type==="text";d.type=S?"password":"text",v.setAttribute("aria-label",S?"\u041F\u043E\u043A\u0430\u0437\u0430\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435":"\u0421\u043A\u0440\u044B\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"),v.title=S?"\u041F\u043E\u043A\u0430\u0437\u0430\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435":"\u0421\u043A\u0440\u044B\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"}),h.append(d,v),r.append(h)}else r.append(d)}d.dataset.projectPath=e;let g=()=>{jw(e,iL(d)),me("\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430 \u0438\u0437\u043C\u0435\u043D\u0435\u043D\u044B. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438\xBB."),e==="deploy.enabled"&&Zn()};if(d.addEventListener("input",g),d.addEventListener("change",g),o&&a!=="checkbox"){let h=document.createElement("small");h.className="field-hint",h.textContent=o,r.append(h)}return r}function wm({kicker:e,title:t,note:a="",fields:n=[],runtime:l=!1,actions:o=null}){let r=document.createElement("section"),i=document.createElement("div"),u=document.createElement("div"),d=document.createElement("div"),m=document.createElement("h3"),f=document.createElement("div");if(r.className="settings-card",i.className="card-head",u.append(d,m),d.className="section-kicker",d.textContent=e,m.textContent=t,i.append(u),a){let g=document.createElement("p");g.className="project-settings-hint",g.textContent=a,i.append(g)}if(f.className=l?"project-settings-runtime":"field-grid",n.forEach(g=>f.append(g)),r.append(i,f),o){let g=document.createElement("div");g.className="project-settings-actions",g.append(...o),r.append(g)}return r}async function M4(e,t=!0){if(!e)return;let a=new FormData;a.append("file",e,e.name);let n=await new Promise((o,r)=>{let i=new XMLHttpRequest;i.open("POST",Ud(`/api/project/upload-site?backup=${t?"1":"0"}`)),i.responseType="json",i.upload.addEventListener("progress",u=>{if(!u.lengthComputable){D(`\u0417\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043C \u0430\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430: ${e.name}...`);return}let d=Math.round(u.loaded/u.total*1e3)/10;D(`\u0417\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043C \u0430\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430: ${d.toLocaleString("ru-RU")}% \xB7 ${e.name}`)}),i.upload.addEventListener("load",()=>{D(`\u0410\u0440\u0445\u0438\u0432 ${e.name} \u043F\u0435\u0440\u0435\u0434\u0430\u043D. \u041F\u0440\u043E\u0432\u0435\u0440\u044F\u0435\u043C \u0438 \u0440\u0430\u0441\u043F\u0430\u043A\u043E\u0432\u044B\u0432\u0430\u0435\u043C \u043D\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435...`)}),i.addEventListener("load",()=>{let u=i.response&&typeof i.response=="object"?i.response:(()=>{try{return JSON.parse(i.responseText||"null")}catch{return null}})();if(i.status===401&&u?.loginUrl){window.location.assign(u.loginUrl),r(new Error("\u0422\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044F \u043F\u043E\u0432\u0442\u043E\u0440\u043D\u044B\u0439 \u0432\u0445\u043E\u0434 \u0432 CMS"));return}if(i.status<200||i.status>=300||!u?.ok){r(new Error(u?.error||"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0430\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430"));return}o(u)}),i.addEventListener("error",()=>r(new Error("\u0421\u043E\u0435\u0434\u0438\u043D\u0435\u043D\u0438\u0435 \u043E\u0431\u043E\u0440\u0432\u0430\u043B\u043E\u0441\u044C \u0432\u043E \u0432\u0440\u0435\u043C\u044F \u0437\u0430\u0433\u0440\u0443\u0437\u043A\u0438 \u0430\u0440\u0445\u0438\u0432\u0430"))),i.send(a)});s.projectConfig=await Oi(),Zn();let l=n.backup?.saved?` \u0411\u044D\u043A\u0430\u043F \u0441\u043E\u0445\u0440\u0430\u043D\u0451\u043D: ${n.backup.fileName} (${n.backup.label}).`:" \u0411\u044D\u043A\u0430\u043F \u043D\u0435 \u0441\u043E\u0437\u0434\u0430\u0432\u0430\u043B\u0441\u044F.";D(`\u0410\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430 \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043D: ${Number(n.files||0).toLocaleString("ru-RU")} \u0444\u0430\u0439\u043B\u043E\u0432, workspace ${n.size?.label||n.label||"\u043E\u0431\u043D\u043E\u0432\u043B\u0435\u043D"}.${l}`)}function A4(){let e=document.createElement("div"),t=document.createElement("span"),a=document.createElement("span"),n=document.createElement("div"),l=document.createElement("button"),o=document.createElement("input"),r=document.createElement("label"),i=document.createElement("input"),u=document.createElement("span"),d=document.createElement("small");return e.className="field-control project-archive-field",t.textContent="\u0410\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430",a.className="field-kind",a.textContent="ZIP",n.className="project-archive-control",l.className="ghost-btn project-archive-button",l.type="button",l.textContent="\u0417\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0430\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430",o.type="file",o.accept=".zip,application/zip",o.className="hidden",r.className="toggle-row project-archive-backup-toggle",i.type="checkbox",i.checked=s.keepSiteArchiveBackup,u.textContent="\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u0431\u044D\u043A\u0430\u043F \u043D\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435",r.append(i,u),d.className="field-hint",d.textContent="\u041F\u0440\u0438 \u0432\u043A\u043B\u044E\u0447\u0451\u043D\u043D\u043E\u043C \u0431\u044D\u043A\u0430\u043F\u0435 \u0438\u0441\u0445\u043E\u0434\u043D\u044B\u0439 ZIP \u0441\u043E\u0445\u0440\u0430\u043D\u044F\u0435\u0442\u0441\u044F \u043E\u0442\u0434\u0435\u043B\u044C\u043D\u043E\u0439 \u0432\u0435\u0440\u0441\u0438\u0435\u0439 \u0432 .cms-backups. ZIP \u0434\u043E\u043B\u0436\u0435\u043D \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C content/pages/home.json, content/knowledge.json, templates \u0438 tools \u0440\u0435\u043D\u0434\u0435\u0440\u0430.",l.addEventListener("click",()=>o.click()),i.addEventListener("change",()=>{s.keepSiteArchiveBackup=i.checked}),o.addEventListener("change",()=>{let m=o.files?.[0];o.value="",M4(m,i.checked).catch(f=>D(f.message))}),n.append(l,o,r),e.append(t,a,n,d),e}function Nd(e,t){let a=document.createElement("div"),n=document.createElement("code");return a.append(`${e}: `,n),n.textContent=t||"\u043D\u0435 \u0437\u0430\u0434\u0430\u043D\u043E",a}function kL({icon:e="ND",title:t,body:a,stateName:n=""}){c.empty.dataset.state=n,c.empty.innerHTML=`
${Ri(e)}

${Ri(t)}

${Ri(a)}

`}function Fd(){eo(),Fm(),c.regions.innerHTML="",c.form.classList.add("hidden"),c.knowledgeForm.classList.add("hidden"),c.projectSettingsForm.classList.add("hidden"),c.empty.classList.remove("hidden");let e=km().missingFiles||[],t=e.length?` \u0421\u0435\u0439\u0447\u0430\u0441 \u043E\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u044E\u0442: ${e.join(", ")}.`:"",a=km().root||s.projectConfig?.runtime?.siteRoot||"",n=a?` \u041B\u043E\u043A\u0430\u043B\u044C\u043D\u0430\u044F \u043F\u0430\u043F\u043A\u0430: ${a}.`:"";kL({icon:"DC",title:"\u0421\u0430\u0439\u0442 \u043D\u0435\u0434\u043E\u0441\u0442\u0443\u043F\u0435\u043D",body:`\u041F\u0440\u043E\u0432\u0435\u0440\u044C\u0442\u0435 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u0438\u044F \u043A \u0445\u043E\u0441\u0442\u0438\u043D\u0433\u0443 \u0438\u043B\u0438 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u0430\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430 \u0432 \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u044B\u0439 workspace CMS.${t}${n}`,stateName:"site-unavailable"}),c.editorHeading&&(c.editorHeading.textContent="DC CMS"),c.selectedRegion.textContent=`DC CMS / ${Pm()} / \u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u0438\u0435`,c.selectedTitle.textContent="\u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0438\u0442\u0435 \u0441\u0430\u0439\u0442",Ia(!1)}function Zn(){if(eo(),c.empty.classList.add("hidden"),c.form.classList.add("hidden"),c.knowledgeForm.classList.add("hidden"),c.projectSettingsForm.classList.remove("hidden"),c.projectSettingsForm.innerHTML="",!s.projectConfig){c.projectSettingsForm.innerHTML='
\u0417\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430...
',Oi().then(Zn).catch(o=>D(o.message));return}if(c.workspaceRole&&(c.workspaceRole.textContent="\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u0438\u044F"),c.editorHeading&&(c.editorHeading.textContent="\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 CMS"),c.selectedRegion.textContent=`DC CMS / ${Pm()} / \u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u0438\u0435`,c.selectedTitle.textContent="\u041F\u0440\u043E\u0435\u043A\u0442 \u0438 \u0434\u0435\u043F\u043B\u043E\u0439",c.save&&(c.save.textContent="\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438",c.save.title="\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0433\u043E \u0441\u0430\u0439\u0442\u0430"),c.render&&(c.render.textContent="\u041F\u0440\u043E\u0432\u0435\u0440\u0438\u0442\u044C \u043F\u0440\u043E\u0435\u043A\u0442",c.render.title="\u041F\u0440\u043E\u0432\u0435\u0440\u0438\u0442\u044C \u0434\u043E\u0441\u0442\u0443\u043F \u043A \u043C\u043E\u0434\u0435\u043B\u0438, \u0431\u0430\u0437\u0435 \u0437\u043D\u0430\u043D\u0438\u0439 \u0438 \u0444\u0430\u0439\u043B\u0430\u043C \u043F\u0440\u043E\u0435\u043A\u0442\u0430"),c.publish){let o=!!s.projectConfig?.deploy?.enabled;c.publish.classList.toggle("hidden",!o),c.publish.disabled=!o||!Yn()||s.projectConfigDirty,c.publish.title=s.projectConfigDirty?"\u0421\u043D\u0430\u0447\u0430\u043B\u0430 \u0441\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u0435 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430":o?"\u041E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u0442\u044C \u0442\u0435\u043A\u0443\u0449\u0443\u044E \u043A\u043E\u043F\u0438\u044E \u0441\u0430\u0439\u0442\u0430 \u043D\u0430 \u0445\u043E\u0441\u0442\u0438\u043D\u0433":"\u0412\u043A\u043B\u044E\u0447\u0438\u0442\u0435 \u0434\u0435\u043F\u043B\u043E\u0439 \u0432 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0430\u0445 \u043F\u0440\u043E\u0435\u043A\u0442\u0430"}let e=wm({kicker:"\u041F\u0440\u043E\u0435\u043A\u0442",title:"\u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u043D\u044B\u0439 \u0441\u0430\u0439\u0442",note:"\u041F\u0440\u043E\u0435\u043A\u0442 \u0445\u0440\u0430\u043D\u0438\u0442\u0441\u044F \u0432 workspace CMS. \u0410\u0440\u0445\u0438\u0432 \u0441\u0430\u0439\u0442\u0430 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u0442\u0441\u044F \u043E\u0434\u0438\u043D \u0440\u0430\u0437 \u0438 \u0434\u0430\u043B\u044C\u0448\u0435 \u0440\u0435\u0434\u0430\u043A\u0442\u0438\u0440\u0443\u0435\u0442\u0441\u044F \u0447\u0435\u0440\u0435\u0437 \u0430\u0434\u043C\u0438\u043D\u043A\u0443.",fields:[Wt({path:"name",label:"\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u043F\u0440\u043E\u0435\u043A\u0442\u0430"}),Wt({path:"publicUrl",label:"\u041F\u0443\u0431\u043B\u0438\u0447\u043D\u044B\u0439 \u0434\u043E\u043C\u0435\u043D",placeholder:"https://nodedc.ru/"}),A4()]}),t=document.createElement("button");t.type="button",t.className="secondary-button",t.textContent="\u041F\u0435\u0440\u0435\u043D\u0435\u0441\u0442\u0438 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u0438 \u0441 \u0434\u0440\u0443\u0433\u043E\u0433\u043E \u0441\u0430\u0439\u0442\u0430",t.disabled=!!s.projectConfig?.deploy?.host||Od.length<2,t.addEventListener("click",()=>Rw().catch(o=>D(o.message)));let a=wm({kicker:"\u041F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u044F",title:"\u0414\u0435\u043F\u043B\u043E\u0439 \u043D\u0430 \u0445\u043E\u0441\u0442\u0438\u043D\u0433",note:"\u0423\u043A\u0430\u0436\u0438\u0442\u0435 \u0434\u043E\u0441\u0442\u0443\u043F \u043A \u0445\u043E\u0441\u0442\u0438\u043D\u0433\u0443. \u041F\u0430\u0440\u043E\u043B\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u044F\u0435\u0442\u0441\u044F \u043D\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435 \u0432 \u0437\u0430\u0448\u0438\u0444\u0440\u043E\u0432\u0430\u043D\u043D\u043E\u043C \u0432\u0438\u0434\u0435 \u0438 \u043D\u0435 \u0432\u043E\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044F \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440.",fields:[t,Wt({path:"deploy.enabled",label:"\u0412\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0434\u0435\u043F\u043B\u043E\u0439",type:"checkbox"}),Wt({path:"deploy.deployOnRender",label:"\u041F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u0442\u044C \u043F\u043E\u0441\u043B\u0435 \u043F\u0435\u0440\u0435\u0441\u0431\u043E\u0440\u043A\u0438",type:"checkbox"}),Wt({path:"deploy.method",label:"\u041C\u0435\u0442\u043E\u0434",options:["sftp","ftp"]}),Wt({path:"deploy.host",label:"FTP / SFTP host",placeholder:"a0000.ftp.mchost.ru"}),Wt({path:"deploy.port",label:"\u041F\u043E\u0440\u0442",type:"number",placeholder:"22"}),Wt({path:"deploy.username",label:"\u041B\u043E\u0433\u0438\u043D"}),Wt({path:"deploy.password",label:"\u041F\u0430\u0440\u043E\u043B\u044C",type:"password",placeholder:s.projectConfig?.deploy?.passwordConfigured?"\u041F\u0430\u0440\u043E\u043B\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D. \u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043D\u043E\u0432\u044B\u0439 \u0434\u043B\u044F \u0437\u0430\u043C\u0435\u043D\u044B":"\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043F\u0430\u0440\u043E\u043B\u044C",hint:s.projectConfig?.deploy?.passwordConfigured?"\u041F\u0430\u0440\u043E\u043B\u044C \u0443\u0436\u0435 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D \u043D\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435. \u041F\u043E\u043B\u0435 \u043F\u0443\u0441\u0442\u043E\u0435, \u043F\u043E\u0442\u043E\u043C\u0443 \u0447\u0442\u043E \u0441\u0435\u043A\u0440\u0435\u0442 \u043D\u0435 \u0432\u043E\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044F \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440.":"\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043F\u0430\u0440\u043E\u043B\u044C \u043E\u0434\u0438\u043D \u0440\u0430\u0437 \u0438 \u043D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438\xBB."}),Wt({path:"deploy.remotePath",label:"\u041F\u0430\u043F\u043A\u0430 \u0441\u0430\u0439\u0442\u0430 \u043D\u0430 \u0445\u043E\u0441\u0442\u0438\u043D\u0433\u0435",placeholder:"httpdocs"})]}),n=s.projectConfig.runtime||{},l=wm({kicker:"Runtime",title:"\u0422\u0435\u043A\u0443\u0449\u0430\u044F \u0441\u0432\u044F\u0437\u043A\u0430",runtime:!0,fields:[Nd("CMS root",n.cmsRoot),Nd("Site root",n.siteRoot),Nd("Config",n.configPath),Nd("\u0412\u0430\u0436\u043D\u043E",n.siteRootChangesRequireRestart?"\u0438\u0437\u043C\u0435\u043D\u0435\u043D\u0438\u0435 siteRoot \u043F\u0440\u0438\u043C\u0435\u043D\u0438\u0442\u0441\u044F \u043F\u043E\u0441\u043B\u0435 \u043F\u0435\u0440\u0435\u0437\u0430\u043F\u0443\u0441\u043A\u0430 CMS":"")]});c.projectSettingsForm.append(e,a,l),Hd()}function D4(){eo(),c.knowledgeForm.classList.add("hidden"),c.projectSettingsForm.classList.add("hidden");let e=$n(),t=we(),a=Ke(),n=s.mode==="seo";if(!t){c.empty.classList.remove("hidden"),c.form.classList.add("hidden"),kL({icon:"ND",title:"\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0431\u043B\u043E\u043A \u0441\u043B\u0435\u0432\u0430",body:"\u0421\u0442\u0430\u0442\u0438\u043A\u0430, hero, \u0444\u043E\u0440\u043C\u0430 \u0438 \u0441\u0435\u043A\u0446\u0438\u0438 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B \u0440\u0430\u0437\u0434\u0435\u043B\u0435\u043D\u044B \u043D\u0430 \u0440\u0430\u0431\u043E\u0447\u0438\u0435 \u0433\u0440\u0443\u043F\u043F\u044B. \u0421\u043D\u0430\u0447\u0430\u043B\u0430 \u0440\u0435\u0434\u0430\u043A\u0442\u0438\u0440\u0443\u0435\u043C typed-\u043F\u043E\u043B\u044F, \u0441\u044B\u0440\u043E\u0439 JSON \u043E\u0441\u0442\u0430\u0432\u043B\u0435\u043D \u043A\u0430\u043A \u0442\u0435\u0445\u043D\u0438\u0447\u0435\u0441\u043A\u0438\u0439 fallback."}),c.selectedRegion.textContent="NODE.DC / \u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0431\u043B\u043E\u043A",c.selectedTitle.textContent=n?"SEO-\u0441\u043B\u043E\u0439":"\u041A\u043E\u043D\u0442\u0435\u043D\u0442\u043D\u044B\u0439 \u0441\u043B\u043E\u0439",Am();return}c.empty.classList.add("hidden"),c.form.classList.remove("hidden"),c.form.dataset.static=String(a),c.form.dataset.mode=s.mode,c.selectedRegion.textContent=n?`NODE.DC / SEO / ${a?"\u0421\u0442\u0440\u0430\u043D\u0438\u0446\u0430":e.label||e.id}`:`NODE.DC / ${e.label||e.id}`,c.selectedTitle.textContent=n?`SEO: ${a?"\u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430":t.adminLabel||t.id}`:t.adminLabel||t.id,c.id.value=t.id||"",c.label.value=t.adminLabel||"",c.template.value=t.template||t.type||"",c.anchor.value=t.anchor||"",c.anchor.placeholder="hub-video / engine-video / applied-modules",c.anchor.title="\u041F\u0443\u0431\u043B\u0438\u0447\u043D\u044B\u0439 Target \u043A\u043E\u043D\u043A\u0440\u0435\u0442\u043D\u043E\u0433\u043E \u0431\u043B\u043E\u043A\u0430: \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u0435\u0442\u0441\u044F \u043A\u0430\u043A \u044F\u043A\u043E\u0440\u044C \u043B\u0435\u043D\u0434\u0438\u043D\u0433\u0430 \u0438 \u043A\u0430\u043A \u0441\u0441\u044B\u043B\u043A\u0430 \u0438\u0437 Knowledge.",Am(),c.enabled.checked=t.enabled!==!1,c.id.readOnly=a,c.anchor.disabled=a,c.enabled.disabled=a,c.enabled.closest(".toggle-row").hidden=a,k4(a||n);try{n?l4(t):ZL(t)}catch(l){E4(l)}c.json.value=JSON.stringify(mL(t),null,2)}function nt(){try{if(!Yn()&&!Nt()){Fd();return}if(Nt()){s.mode==="knowledge"&&s.knowledge?(op(),Kd()):Dm(),Zn();return}if(s.mode==="knowledge"){uo();return}Dm(),D4()}catch(e){console.error(e),D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0435\u043D\u0434\u0435\u0440\u0430 \u0430\u0434\u043C\u0438\u043D\u043A\u0438: ${e.message}`)}}function Tm(){let e=we();if(e){if(x2(),e.adminLabel=c.label.value.trim()||e.adminLabel||e.id,!Ke()){e.id=c.id.value.trim(),e.anchor=Pd(c.anchor.value)||null,c.anchor.value=e.anchor||"",e.enabled=c.enabled.checked,Am();let t=hL().find(a=>a.second.block===e||a.first.block===e);t&&D(`Target \xAB${t.target}\xBB \u0443\u0436\u0435 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u0435\u0442\u0441\u044F \u0432 \u0434\u0440\u0443\u0433\u043E\u043C \u0431\u043B\u043E\u043A\u0435. \u041F\u0435\u0440\u0435\u0438\u043C\u0435\u043D\u0443\u0439\u0442\u0435 \u043E\u0434\u0438\u043D \u0438\u0437 target-\u043E\u0432 \u043F\u0435\u0440\u0435\u0434 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0438\u0435\u043C.`)}c.json.value=JSON.stringify(e,null,2),Dm(),me()}}function T4(e){let t=new Map;for(let a of e.editableFields??[]){let n=a.group||gL(a.path);t.has(n)||t.set(n,[]),t.get(n).push(a)}return t}function Vv(e,t){e.classList.remove("is-image","is-video","is-solid-dark"),e.innerHTML="",e.title="",t&&(t.textContent="")}function N4(e,t,a,n){if(!(!a||!x4(n)))try{let o=document.createElement("canvas"),r=o.getContext("2d",{willReadFrequently:!0});if(!r)return;o.width=24,o.height=24,r.drawImage(e,0,0,24,24);let i=r.getImageData(0,0,24,24).data,u=0,d=0,m=0;for(let v=0;v<24;v+=1)for(let S=0;S<24;S+=1){let C=(v*24+S)*4;if(i[C+3]<240)continue;u+=1;let p=S<=1||v<=1||S>=22||v>=22,y=i[C]+i[C+1]+i[C+2]<66;p&&(d+=1,y&&(m+=1))}let f=576,g=d?m/d:0;u/f>.92&&g>.82&&(t.classList.add("is-solid-dark"),a.textContent="\u0424\u0430\u0439\u043B \u0441 \u043D\u0435\u043F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u044B\u043C \u0442\u0451\u043C\u043D\u044B\u043C \u0444\u043E\u043D\u043E\u043C. \u0414\u043B\u044F \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u0430 \u043D\u0430 \u0442\u0451\u043C\u043D\u043E\u043C \u0438\u043D\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0435 \u043B\u0443\u0447\u0448\u0435 PNG/SVG \u0441 \u043F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u043E\u0441\u0442\u044C\u044E.")}catch{}}function Qm(e,t,a=null,n=null){Vv(e,a);let l=Bi(t),o=g4(t);if(!l){e.textContent="FILE";return}if(o==="video"){let r=document.createElement("video");e.classList.add("is-video"),r.src=l,r.autoplay=!0,r.loop=!0,r.muted=!0,r.playsInline=!0,e.append(r);return}if(o==="image"){let r=document.createElement("img");e.classList.add("is-image"),r.src=l,r.alt="",r.loading="lazy",r.addEventListener("load",()=>N4(r,e,a,n)),r.addEventListener("error",()=>{Vv(e,a),e.textContent="FILE",a&&(a.textContent="\u041F\u0440\u0435\u0432\u044C\u044E \u043D\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u043B\u043E\u0441\u044C. \u041F\u0440\u043E\u0432\u0435\u0440\u044C\u0442\u0435 \u043F\u0443\u0442\u044C \u0438\u043B\u0438 \u0432\u043D\u0435\u0448\u043D\u0438\u0439 URL.")}),e.append(r);return}e.textContent="FILE"}function Wm({block:e,editableField:t,hiddenInput:a,urlInput:n,fileName:l,preview:o,hint:r,value:i}){a.value=i,n.value=i,l.textContent=zi(Ca(i),28),l.title=Ca(i),Rt(e,t.path,i),Qm(o,i,r,t),we()===e&&(c.json.value=JSON.stringify(e,null,2)),me()}async function EL({block:e,editableField:t,hiddenInput:a,urlInput:n,fileName:l,preview:o,hint:r,error:i,setSource:u,afterUpload:d,file:m}){if(m){s.mediaUploadActive=!0,Gn(!0),Ht(),i.textContent="",l.textContent="\u0421\u043E\u0445\u0440\u0430\u043D\u044F\u0435\u043C \u0432 assets...";try{let f=new FormData;f.append("file",m,m.name),f.append("fileName",m.name),f.append("mimeType",m.type||"application/octet-stream"),f.append("bucket",$m(e,t));let g=await Me("/api/upload/asset",{method:"POST",body:f}),h=await g.json().catch(()=>({ok:!1,error:`\u0421\u0435\u0440\u0432\u0435\u0440 \u0432\u0435\u0440\u043D\u0443\u043B ${g.status}`}));if(!g.ok||!h.ok)throw new Error(h.error||"\u0424\u0430\u0439\u043B \u043D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C");return Wm({block:e,editableField:t,hiddenInput:a,urlInput:n,fileName:l,preview:o,hint:r,value:h.url}),u("file"),me(`\u0424\u0430\u0439\u043B \u0441\u043E\u0445\u0440\u0430\u043D\u0451\u043D: ${h.url}. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB, \u0447\u0442\u043E\u0431\u044B \u0437\u0430\u043F\u0438\u0441\u0430\u0442\u044C \u043F\u0443\u0442\u044C \u0432 content/pages/home.json.`),typeof d=="function"&&await d(h),h}catch(f){return i.textContent=f.message,l.textContent=zi(Ca(a.value),28),D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0437\u0430\u0433\u0440\u0443\u0437\u043A\u0438: ${f.message}`),null}finally{s.mediaUploadActive=!1,hn.value="",Gn(!1),Ht()}}}function R4(e){Gn(!0),Ht(),window.clearTimeout(s.filePickerResetTimer),hn.accept=nL,hn.value="",hn.oncancel=()=>{Gn(!1),Ht()},hn.onchange=async()=>{let t=hn.files?.[0];if(!t){Gn(!1),Ht();return}await EL({...e,file:t})},window.addEventListener("focus",()=>{window.setTimeout(()=>{s.mediaUploadActive||hn.files?.length||(Gn(!1),Ht())},180)},{once:!0});try{hn.click()}catch(t){Gn(!1),Ht(),e.error.textContent=t.message,D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043E\u0442\u043A\u0440\u044B\u0442\u0438\u044F \u0432\u044B\u0431\u043E\u0440\u0430 \u0444\u0430\u0439\u043B\u0430: ${t.message}`)}}function B4(e,t,{large:a=!1}={}){if(e.innerHTML="",e.classList.remove("is-image","is-video"),!t){e.textContent="FILE";return}if(t.kind==="image"){let l=document.createElement("img");e.classList.add("is-image"),l.src=Bi(t.url),l.alt=t.name||"",l.loading="lazy",l.decoding="async",e.append(l);return}if(t.kind==="video"){let l=document.createElement("video");e.classList.add("is-video"),l.src=Bi(t.url),l.muted=!0,l.loop=!0,l.playsInline=!0,l.preload="metadata",a&&(l.controls=!0),e.append(l);return}let n=t.kind==="model"?"3D":t.kind==="font"?"FONT":t.extension?.toUpperCase()||"FILE";e.textContent=n}function _4(){c.mediaKindFilters.innerHTML="",c.mediaRootFilters.innerHTML="";let e=O4();for(let[t,a]of Hw){let n=document.createElement("button");n.type="button",n.className="media-filter-button",n.dataset.active=String(s.mediaLibrary.kind===t),n.disabled=s.mediaLibrary.trashMode,n.textContent=a,n.addEventListener("click",()=>{s.mediaLibrary.kind=t,lt()}),c.mediaKindFilters.append(n)}for(let[t,a]of lL){let n=document.createElement("button");n.type="button",n.className="media-filter-button",n.dataset.active=String(e===t),n.disabled=s.mediaLibrary.trashMode,n.textContent=a,n.title=t||"\u041A\u043E\u0440\u0435\u043D\u044C \u043F\u0440\u043E\u0435\u043A\u0442\u0430 NODEDC_SITE",n.addEventListener("click",async()=>{s.mediaLibrary.root=t,s.mediaLibrary.selectedEntry=null,s.mediaLibrary.selectedUrl="",await je(t).catch(l=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043C\u0435\u0434\u0438\u0430\u0442\u0435\u043A\u0438: ${l.message}`))}),c.mediaRootFilters.append(n)}}function Jm(e){return String(e||"").split("/").filter(Boolean)}function ML(e,t){return t?e===t||e.startsWith(`${t}/`):!e}function O4(){let e=s.mediaLibrary.selectedPath||s.mediaLibrary.root||"",t="";for(let[a]of lL)a&&ML(e,a)&&(t=a);return t}function z4(e){let t=Jm(e),a=[""],n="";for(let l of t)n=n?`${n}/${l}`:l,a.push(n);return a}function xt(e){let t=Jm(e);return t.pop(),t.join("/")}function AL(e){let t=String(e||"").replace(/^\/+/,"");t!=="__trash__"&&(s.mediaLibrary.lastPath=t,Jl({lastMediaDirectory:t}))}function wa(e){let t=String(e||"").split("?")[0].split("#")[0];t.startsWith("./")&&(t=t.slice(2));try{t=decodeURIComponent(t)}catch{}return t}function q4(e){let t=wa(e);if(!t)return[];let a=t.split("/").map(l=>encodeURIComponent(l)).join("/"),n=[t,`./${t}`,`/${t}`,a,`./${a}`,`/${a}`];return[...new Set(n)].sort((l,o)=>o.length-l.length)}function DL(e,t){let a=e;for(let n of t){let l=q4(n.fromUrl||n.from),o=wa(n.toUrl||n.to);if(!l.length||!o)continue;let r=o.split("/").map(i=>encodeURIComponent(i)).join("/");for(let i of l){let u=i.startsWith("./"),d=i.startsWith("/"),m=`${u?"./":d?"/":""}${i.includes("%")?r:o}`;a=a.split(i).join(m)}}return a}function Nm(e,t){if(typeof e=="string")return DL(e,t);if(Array.isArray(e)){let a=!1,n=e.map(l=>{let o=Nm(l,t);return a||=o!==l,o});return a?n:e}if(e&&typeof e=="object"){let a=!1,n={...e};for(let[l,o]of Object.entries(e)){let r=Nm(o,t);r!==o&&(n[l]=r,a=!0)}return a?n:e}return e}async function U4(e){let t=await Me(`/api/media/browse?path=${encodeURIComponent(e||"")}`),a=await t.json().catch(()=>({ok:!1,error:`\u0421\u0435\u0440\u0432\u0435\u0440 \u0432\u0435\u0440\u043D\u0443\u043B ${t.status}`}));if(!t.ok||!a.ok)throw new Error(a.error||"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0442\u043A\u0440\u044B\u0442\u044C \u043F\u0430\u043F\u043A\u0443");return a}async function gn(){if(!c.mediaSiteSize)return;c.mediaSiteSize.textContent="\u0421\u0430\u0439\u0442: \u0441\u0447\u0438\u0442\u0430\u0435\u043C...";let e=await Me("/api/media/site-size"),t=await e.json().catch(()=>({ok:!1,error:`\u0421\u0435\u0440\u0432\u0435\u0440 \u0432\u0435\u0440\u043D\u0443\u043B ${e.status}`}));if(!e.ok||!t.ok)throw c.mediaSiteSize.textContent="\u0421\u0430\u0439\u0442: --",new Error(t.error||"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043F\u043E\u0441\u0447\u0438\u0442\u0430\u0442\u044C \u0440\u0430\u0437\u043C\u0435\u0440 \u0441\u0430\u0439\u0442\u0430");c.mediaSiteSize.textContent=`\u0421\u0430\u0439\u0442: ${t.label}`,c.mediaSiteSize.title=`${Number(t.bytes||0).toLocaleString("ru-RU")} \u0431\u0430\u0439\u0442`}async function xn(e,t={}){let a=await Me(e,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(t)}),n=await a.json().catch(()=>({ok:!1,error:`\u0421\u0435\u0440\u0432\u0435\u0440 \u0432\u0435\u0440\u043D\u0443\u043B ${a.status}`}));if(!a.ok||!n.ok)throw new Error(n.error||"\u041E\u043F\u0435\u0440\u0430\u0446\u0438\u044F \u043D\u0435 \u0432\u044B\u043F\u043E\u043B\u043D\u0435\u043D\u0430");return n}function jd(e){return Array.from(e.dataTransfer?.types||[]).includes(Hm)}function TL(e){let t=e.dataTransfer?.getData(Hm);if(!t)return null;try{return JSON.parse(t)}catch{return null}}function H4(e,t){if(!e||!t)return;let{block:a,editableField:n,hiddenInput:l,urlInput:o,fileName:r,preview:i,hint:u}=e;l.value=t,o.value=t,r.textContent=zi(Ca(t),28),r.title=Ca(t),Rt(a,n.path,t),Qm(i,t,u,n),we()===a&&(c.json.value=JSON.stringify(a,null,2)),e.setSource("file")}function NL(e=[]){let t=s.mediaLibrary.context;if(!Array.isArray(e)||!e.length)return!1;let a=!1,n=t?.hiddenInput?wa(t.hiddenInput.value||""):"",l=Nm(s.page,e);if(l!==s.page&&(s.page=l,a=!0),document.querySelectorAll("input.service-media-hidden-input").forEach(r=>{let i=DL(r.value||"",e);if(i===r.value)return;r.value=i;let u=r.closest(".service-media-field"),d=u?.querySelector(".service-media-file-name"),m=u?.querySelector(".service-media-url-input");m&&(m.value=i),d&&(d.textContent=zi(Ca(i),28),d.title=Ca(i)),a=!0}),we()&&(c.json.value=JSON.stringify(we(),null,2)),!t?.hiddenInput)return a;let o=e.find(r=>wa(r.fromUrl||r.from||"")===n);return o?.toUrl?(H4(t,o.toUrl),!0):a}function ep(e,t){if(!e||s.mediaLibrary.trashMode||!e.path)return!1;let a=String(t||"").replace(/^\/+/,""),n=xt(e.path);return e.type==="directory"&&(a===e.path||a.startsWith(`${e.path}/`))?!1:a!==n}function Gd(e,t){if(e){if(t){e.dataset.dropActive="true";return}delete e.dataset.dropActive}}function RL(e,t){if(!jd(e))return;let a=TL(e)||Pt(s.mediaLibrary.dragEntryPath);e.preventDefault(),e.stopPropagation(),e.dataTransfer.dropEffect=ep(a,t)?"move":"none",Gd(e.currentTarget,e.dataTransfer.dropEffect==="move")}function BL(e){e.currentTarget.contains(e.relatedTarget)||Gd(e.currentTarget,!1)}async function P4(e,t){if(!ep(e,t))return;let a=await xn("/api/media/move",{path:e.path,targetPath:t});NL(a.replacements);let n=xt(a.path);await je(n,{selectedUrl:a.url||""});let l=Pt(a.path);l&&(s.mediaLibrary.selectedPath=n,s.mediaLibrary.selectedEntry=l,s.mediaLibrary.selectedUrl=l.type==="file"&&l.url||"",lt());let o=Array.isArray(a.updatedFiles)?a.updatedFiles.length:0;D(`\u041F\u0435\u0440\u0435\u043D\u0435\u0441\u0435\u043D\u043E: ${a.path}${o?`. \u0421\u0441\u044B\u043B\u043A\u0438 \u043E\u0431\u043D\u043E\u0432\u043B\u0435\u043D\u044B: ${o}`:""}.`)}function _L(e,t){if(!jd(e))return;let a=TL(e)||Pt(s.mediaLibrary.dragEntryPath);e.preventDefault(),e.stopPropagation(),Gd(e.currentTarget,!1),ep(a,t)&&P4(a,t).catch(n=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043F\u0435\u0440\u0435\u043D\u043E\u0441\u0430: ${n.message}`))}async function F4(){let e=await Me("/api/media/trash"),t=await e.json().catch(()=>({ok:!1,error:`\u0421\u0435\u0440\u0432\u0435\u0440 \u0432\u0435\u0440\u043D\u0443\u043B ${e.status}`}));if(!e.ok||!t.ok)throw new Error(t.error||"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0442\u043A\u0440\u044B\u0442\u044C \u0443\u0434\u0430\u043B\u0451\u043D\u043D\u044B\u0435");return{ok:!0,path:"__trash__",breadcrumbs:[{name:"\u0423\u0434\u0430\u043B\u0451\u043D\u043D\u044B\u0435",path:"__trash__"}],entries:t.files||[]}}function OL(e){let t=s.mediaLibrary.query.trim().toLowerCase();return t&&![e.name,e.path,e.url,zd(e)].filter(Boolean).some(n=>String(n).toLowerCase().includes(t))?!1:e.type==="directory"||s.mediaLibrary.kind==="all"?!0:e.kind===s.mediaLibrary.kind}function j4(e){for(let t of s.mediaLibrary.columns){let a=t.entries.find(n=>n.url===e);if(a)return a}return null}function Pt(e){if(!e)return null;for(let t of s.mediaLibrary.columns){let a=t.entries.find(n=>n.path===e);if(a)return a}return null}function qd(e){if(!e||s.mediaLibrary.trashMode)return!1;if(e.type==="directory")return e.path?.startsWith("assets/")&&!e.path.split("/").includes(".trash");let t=s.mediaLibrary.context?.hiddenInput?.value===e.url;return e.type==="file"&&e.writable&&Ym(e)==="unused"&&!t}function tp(e,t=s.mediaLibrary.selectedPath){e&&(e.type==="file"?(s.mediaLibrary.selectedPath=t,s.mediaLibrary.selectedUrl=e.url||""):s.mediaLibrary.selectedUrl="",s.mediaLibrary.selectedEntry=e,lt())}function ro(){c.mediaContextMenu.classList.add("hidden"),c.mediaContextMenu.innerHTML="",s.mediaLibrary.contextMenu=null}function Wl(e,t,{disabled:a=!1}={}){let n=document.createElement("button");n.type="button",n.setAttribute("role","menuitem"),n.textContent=e,n.disabled=a,n.addEventListener("click",()=>{ro(),t()}),c.mediaContextMenu.append(n)}function zL(e,{entry:t=null,columnPath:a=s.mediaLibrary.selectedPath}={}){if(e.preventDefault(),ro(),s.mediaLibrary.contextMenu={entry:t,columnPath:a},t&&tp(t,a),s.mediaLibrary.trashMode?t?.type==="file"&&(Wl("\u0412\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442\u044C",()=>jL().catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0432\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D\u0438\u044F: ${r.message}`))),Wl("\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u043D\u0430\u0432\u0441\u0435\u0433\u0434\u0430",()=>GL().catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u044F \u0438\u0437 \u043A\u043E\u0440\u0437\u0438\u043D\u044B: ${r.message}`)))):t?.type==="file"||t?.type==="directory"?(Wl("\u0414\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C",()=>l2(t).catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u044F: ${r.message}`))),Wl("\u041F\u0435\u0440\u0435\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u0442\u044C",()=>n2(t).catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043F\u0435\u0440\u0435\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u043D\u0438\u044F: ${r.message}`))),Wl("\u0423\u0434\u0430\u043B\u0438\u0442\u044C",()=>np().catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u044F: ${r.message}`)),{disabled:!qd(t)})):Wl("\u0421\u043E\u0437\u0434\u0430\u0442\u044C \u043F\u0430\u043F\u043A\u0443",()=>a2(a).catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0441\u043E\u0437\u0434\u0430\u043D\u0438\u044F \u043F\u0430\u043F\u043A\u0438: ${r.message}`))),!c.mediaContextMenu.children.length)return;c.mediaContextMenu.classList.remove("hidden");let n=c.mediaContextMenu.getBoundingClientRect(),l=Math.min(e.clientX,window.innerWidth-n.width-12),o=Math.min(e.clientY,window.innerHeight-n.height-12);c.mediaContextMenu.style.left=`${Math.max(12,l)}px`,c.mediaContextMenu.style.top=`${Math.max(12,o)}px`}function G4(){window.requestAnimationFrame(()=>{let t=[...c.mediaList.querySelectorAll(".media-column")].at(-1),n=c.mediaList.querySelector('.media-entry[data-exact-active="true"]')||c.mediaList.querySelector('.media-entry[data-active="true"]');if(t){let o=Math.max(0,c.mediaList.scrollWidth-c.mediaList.clientWidth),r=t.offsetLeft+t.offsetWidth+14,i=t.offsetLeft-14,u=c.mediaList.scrollLeft;r>u+c.mediaList.clientWidth&&(u=r-c.mediaList.clientWidth),im+l.clientHeight&&(m=i-l.clientHeight),u{let n=document.createElement("button");n.type="button",n.className="media-breadcrumb-button",n.textContent=t.name,n.dataset.active=String(a===e.length-1),n.addEventListener("click",()=>{s.mediaLibrary.root=t.path,s.mediaLibrary.selectedEntry=null,s.mediaLibrary.selectedUrl="",je(t.path).catch(l=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043C\u0435\u0434\u0438\u0430\u0442\u0435\u043A\u0438: ${l.message}`))}),c.mediaBreadcrumbs.append(n)})}function X4(e,t){let a=document.createElement("button"),n=document.createElement("span"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("span"),d=s.mediaLibrary.selectedEntry?.path===e.path,m=d||e.type==="directory"&&ML(s.mediaLibrary.selectedPath,e.path);if(a.type="button",a.className="media-entry",a.dataset.type=e.type,a.dataset.path=e.path,a.dataset.active=String(m),a.dataset.exactActive=String(d),a.title=e.url||e.path,a.draggable=!s.mediaLibrary.trashMode,n.className="media-entry-icon",e.type==="file"&&e.url&&e.kind==="image"){let f=document.createElement("img");n.classList.add("is-preview"),f.src=Bi(e.url),f.alt="",f.loading="lazy",f.decoding="async",n.append(f)}else if(e.type==="file"&&e.url&&e.kind==="video"){let f=document.createElement("video");n.classList.add("is-preview"),f.src=Bi(e.url),f.muted=!0,f.playsInline=!0,f.preload="metadata",n.append(f)}else n.textContent=e.type==="directory"?"DIR":e.kind==="model"?"3D":e.kind==="font"?"Aa":e.extension?.toUpperCase()||"FILE";return l.className="media-entry-copy",o.className="media-entry-name",o.textContent=e.name,r.className="media-entry-meta",r.textContent=e.type==="directory"?e.path||"\u041A\u043E\u0440\u0435\u043D\u044C \u043F\u0440\u043E\u0435\u043A\u0442\u0430":[zd(e),e.extension,xL(e.size)].filter(Boolean).join(" \xB7 "),l.append(o,r),i.className="media-status-dot media-entry-status",i.dataset.status=Ym(e),i.title=zd(e),u.className="media-entry-arrow",u.textContent=e.type==="directory"?"\u203A":"",a.append(n,l),e.type==="file"&&a.append(i),a.append(u),a.addEventListener("click",async()=>{if(e.type==="directory"){s.mediaLibrary.root=e.path,s.mediaLibrary.selectedEntry=e,s.mediaLibrary.selectedUrl="",await je(e.path);return}tp(e,t)}),a.addEventListener("contextmenu",f=>{f.stopPropagation(),zL(f,{entry:e,columnPath:t})}),a.addEventListener("dblclick",()=>{e.type==="file"&&e.selectable&&FL()}),a.addEventListener("dragstart",f=>{if(s.mediaLibrary.trashMode){f.preventDefault();return}let g=JSON.stringify({path:e.path,type:e.type});s.mediaLibrary.dragEntryPath=e.path,a.dataset.dragging="true",f.dataTransfer.effectAllowed="move",f.dataTransfer.setData(Hm,g),f.dataTransfer.setData("text/plain",e.path)}),a.addEventListener("dragend",()=>{s.mediaLibrary.dragEntryPath="",delete a.dataset.dragging,c.mediaList.querySelectorAll("[data-drop-active]").forEach(f=>Gd(f,!1))}),e.type==="directory"&&(a.addEventListener("dragover",f=>RL(f,e.path)),a.addEventListener("dragleave",BL),a.addEventListener("drop",f=>_L(f,e.path))),a}function K4(e){let t=document.createElement("section"),a=document.createElement("div"),n=document.createElement("div"),l=document.createElement("div"),o=document.createElement("div"),r=(e.entries||[]).filter(OL);t.className="media-column",a.className="media-column-head",n.className="media-column-title",n.textContent=e.path?Jm(e.path).at(-1):"NODEDC_SITE",l.className="media-column-count",l.textContent=`${r.length}`,a.append(n,l),o.className="media-column-list",o.dataset.path=e.path||"",o.addEventListener("dragover",i=>RL(i,e.path||"")),o.addEventListener("dragleave",BL),o.addEventListener("drop",i=>_L(i,e.path||"")),o.addEventListener("contextmenu",i=>{i.target.closest(".media-entry")||zL(i,{columnPath:e.path||""})});for(let i of r)o.append(X4(i,e.path));if(!r.length){let i=document.createElement("div");i.className="media-column-empty",i.textContent="\u041F\u0443\u0441\u0442\u043E",o.append(i)}return t.append(a,o),t}function qL(e){return s.mediaLibrary.columns.find(t=>t.path===e)||null}function UL(e){if(!e?.path)return"";let t=HL(e)||qL(xt(e.path));if(!t)return"";let a=ap(t),n=a.findIndex(o=>o.path===e.path),l=n>=0?a[n+1]||a[n-1]:null;return l||(n=t.entries.findIndex(o=>o.path===e.path),l=n>=0?t.entries[n+1]||t.entries[n-1]:null),l?.path||""}function ap(e){return(e?.entries||[]).filter(OL)}function HL(e){return e&&s.mediaLibrary.columns.find(t=>t.entries.some(a=>a.path===e.path))||null}function Y4(){return HL(s.mediaLibrary.selectedEntry)||s.mediaLibrary.columns.find(e=>e.path===s.mediaLibrary.selectedPath)||s.mediaLibrary.columns.at(-1)||null}async function Xv(e){let t=Y4(),a=ap(t);if(!t||!a.length)return;let n=a.findIndex(i=>i.path===s.mediaLibrary.selectedEntry?.path),l=e>0?0:a.length-1,o=n<0?l:Math.min(Math.max(n+e,0),a.length-1),r=a[o];if(r.type==="directory"&&!s.mediaLibrary.trashMode){s.mediaLibrary.root=r.path,s.mediaLibrary.selectedUrl="",await je(r.path,{selectedUrl:""});let i=Pt(r.path);i&&(s.mediaLibrary.selectedPath=t.path,s.mediaLibrary.selectedEntry=i,s.mediaLibrary.selectedUrl="",lt());return}tp(r,t.path)}async function $4(){let e=s.mediaLibrary.selectedEntry;if(!e||e.type!=="directory"||s.mediaLibrary.trashMode)return;s.mediaLibrary.root=e.path,s.mediaLibrary.selectedEntry=e,s.mediaLibrary.selectedUrl="",await je(e.path,{selectedUrl:""});let t=qL(e.path),a=ap(t)[0];a&&(s.mediaLibrary.selectedPath=e.path,s.mediaLibrary.selectedEntry=a,s.mediaLibrary.selectedUrl=a.type==="file"&&a.url||"",lt())}async function Z4(){if(s.mediaLibrary.trashMode)return;let e=s.mediaLibrary.selectedPath||s.mediaLibrary.selectedEntry?.path||"";if(!e)return;let t=xt(e);s.mediaLibrary.selectedUrl="",await je(t,{selectedUrl:""});let a=Pt(e);a&&(s.mediaLibrary.selectedPath=t,s.mediaLibrary.selectedEntry=a,s.mediaLibrary.selectedUrl="",lt())}function Q4(e){return!!e?.closest?.("input, textarea, select, [contenteditable='true']")}function W4(){let e=qi(),t=s.mediaLibrary.selectedEntry,a=c.mediaPreviewUsage.lastElementChild;if(B4(c.mediaPreview,e,{large:!0}),c.mediaSelect.textContent=s.mediaLibrary.trashMode?"\u0412\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442\u044C":"\u0412\u044B\u0431\u0440\u0430\u0442\u044C",c.mediaSelect.disabled=!e,c.mediaDelete.disabled=!0,!t){c.mediaPreviewName.textContent="\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0444\u0430\u0439\u043B \u0438\u043B\u0438 \u043F\u0430\u043F\u043A\u0443",c.mediaPreviewPath.textContent=s.mediaLibrary.selectedPath||"NODEDC_SITE",c.mediaPreviewMeta.textContent="Column view \u043F\u0440\u043E\u0435\u043A\u0442\u0430",c.mediaPreviewUsage.dataset.status="idle",a&&(a.textContent="\u041D\u0435\u0442 \u0432\u044B\u0431\u043E\u0440\u0430");return}if(t.type==="directory"){let l=qd(t);c.mediaPreview.innerHTML="DIR",c.mediaPreviewName.textContent=t.name,c.mediaPreviewPath.textContent=t.path||"NODEDC_SITE",c.mediaPreviewPath.title=t.path||"NODEDC_SITE",c.mediaPreviewMeta.textContent="\u041F\u0430\u043F\u043A\u0430 \u043F\u0440\u043E\u0435\u043A\u0442\u0430",c.mediaPreviewUsage.dataset.status="idle",a&&(a.textContent="\u041F\u0430\u043F\u043A\u0430"),c.mediaDelete.disabled=!l,c.mediaDelete.title=l?"\u041F\u0435\u0440\u0435\u043D\u0435\u0441\u0442\u0438 \u043F\u0430\u043F\u043A\u0443 \u0432 assets/.trash":"\u0423\u0434\u0430\u043B\u0435\u043D\u0438\u0435 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u043E \u0442\u043E\u043B\u044C\u043A\u043E \u0434\u043B\u044F \u043F\u0430\u043F\u043E\u043A \u0432\u043D\u0443\u0442\u0440\u0438 assets";return}if(s.mediaLibrary.trashMode){c.mediaSelect.disabled=!t.restorable,c.mediaPreviewName.textContent=t.originalName||t.name,c.mediaPreviewPath.textContent=t.originalPath||t.path,c.mediaPreviewPath.title=t.originalPath||t.path,c.mediaPreviewMeta.textContent=[jv(t),Fv(t.mtimeMs)].filter(Boolean).join(" \xB7 "),c.mediaPreviewUsage.dataset.status="trash",a&&(a.textContent="\u0423\u0434\u0430\u043B\u0451\u043D"),c.mediaDelete.disabled=!t.trashPath,c.mediaDelete.title="\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u044B\u0439 \u0444\u0430\u0439\u043B \u0438\u0437 \u043A\u043E\u0440\u0437\u0438\u043D\u044B \u043D\u0430\u0432\u0441\u0435\u0433\u0434\u0430";return}let n=qd(t);c.mediaSelect.disabled=!t.selectable,c.mediaPreviewName.textContent=t.name,c.mediaPreviewPath.textContent=t.url||t.path,c.mediaPreviewPath.title=t.url||t.path,c.mediaPreviewMeta.textContent=[jv(t),Fv(t.mtimeMs)].filter(Boolean).join(" \xB7 "),c.mediaPreviewUsage.dataset.status=Ym(t),a&&(a.textContent=t.selectable?zd(t):"\u041D\u0435 \u043F\u0443\u0431\u043B\u0438\u0447\u043D\u044B\u0439 asset"),c.mediaDelete.disabled=!n,c.mediaDelete.title=n?"\u041F\u0435\u0440\u0435\u043D\u0435\u0441\u0442\u0438 unused-\u0444\u0430\u0439\u043B \u0432 assets/.trash":"\u0423\u0434\u0430\u043B\u0435\u043D\u0438\u0435 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u043E \u0442\u043E\u043B\u044C\u043A\u043E \u0434\u043B\u044F unused-\u0444\u0430\u0439\u043B\u043E\u0432 \u0438\u0437 assets"}function lt(){c.mediaTrashToggle.dataset.active=String(s.mediaLibrary.trashMode),c.mediaUpload.textContent=s.mediaLibrary.trashMode?"\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u044C \u043A\u043E\u0440\u0437\u0438\u043D\u0443":"+ \u0417\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C",_4(),V4(),c.mediaList.innerHTML="",c.mediaList.classList.add("media-columns");let e=s.mediaLibrary.columns||[];c.mediaEmpty.classList.toggle("hidden",e.length>0);for(let t of e)c.mediaList.append(K4(t));W4(),G4()}async function J4(){if(await gn().catch(e=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${e.message}`)),s.mediaLibrary.trashMode){await Hi({selectedTrashPath:s.mediaLibrary.selectedEntry?.trashPath||""});return}await je(s.mediaLibrary.selectedPath||s.mediaLibrary.root||"")}async function e2(){if(s.mediaLibrary.trashMode){await je(s.mediaLibrary.previousPath||s.mediaLibrary.root||"");return}s.mediaLibrary.previousPath=s.mediaLibrary.selectedPath||s.mediaLibrary.root||"",s.mediaLibrary.selectedEntry=null,s.mediaLibrary.selectedUrl="",await Hi()}async function PL(e){let t=e.hiddenInput?.value||"",a=wa(t),n=`assets/uploads/${$m(e.block,e.editableField)}`,o=s.mediaLibrary.lastPath||aL()||(a?xt(a):n);s.mediaLibrary.context=e,s.mediaLibrary.trashMode=!1,s.mediaLibrary.previousPath="",s.mediaLibrary.selectedUrl=t,s.mediaLibrary.selectedEntry=null,s.mediaLibrary.selectedPath=o,s.mediaLibrary.query="",s.mediaLibrary.root=o,s.mediaLibrary.kind="all",c.mediaSearch.value="",c.mediaModalTitle.textContent=e.editableField.label||"\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0444\u0430\u0439\u043B",c.mediaModalSubtitle.textContent=`${e.editableField.path} -> ${n}`,c.mediaModal.classList.remove("hidden"),c.mediaSearch.focus(),gn().catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${r.message}`));try{await je(o,{selectedUrl:t})}catch(r){D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043C\u0435\u0434\u0438\u0430\u0442\u0435\u043A\u0438: ${r.message}`),lt()}}function Pi(){ro(),c.mediaModal.classList.add("hidden"),delete c.mediaDropZone.dataset.dragActive,s.mediaLibrary.context=null,s.mediaLibrary.trashMode=!1,s.mediaLibrary.selectedUrl="",s.mediaLibrary.selectedEntry=null,Ht()}function FL(){let e=qi(),t=s.mediaLibrary.context;if(!(!e||!t)){if(s.mediaLibrary.trashMode){jL().catch(a=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0432\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D\u0438\u044F: ${a.message}`));return}typeof t.onSelect=="function"?t.onSelect(e.url,e):(Wm({...t,value:e.url}),t.setSource("file")),AL(e.directory||xt(wa(e.url))),Pi(),me(`\u0412\u044B\u0431\u0440\u0430\u043D \u0444\u0430\u0439\u043B: ${e.url}. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB, \u0447\u0442\u043E\u0431\u044B \u0437\u0430\u043F\u0438\u0441\u0430\u0442\u044C \u043F\u0443\u0442\u044C.`)}}async function jL(){let e=qi();if(!e?.trashPath)return;let t=await xn("/api/media/restore",{trashPath:e.trashPath});await Hi(),await gn().catch(a=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${a.message}`)),D(`\u0424\u0430\u0439\u043B \u0432\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D: ${t.path}.`)}async function t2(){await oo({title:"\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u044C \u043A\u043E\u0440\u0437\u0438\u043D\u0443?",body:"\u0412\u0441\u0435 \u0444\u0430\u0439\u043B\u044B \u0438\u0437 \u0443\u0434\u0430\u043B\u0451\u043D\u043D\u044B\u0445 \u0431\u0443\u0434\u0443\u0442 \u0443\u0434\u0430\u043B\u0435\u043D\u044B \u043E\u043A\u043E\u043D\u0447\u0430\u0442\u0435\u043B\u044C\u043D\u043E."})&&(await xn("/api/media/trash/clear"),await Hi(),await gn().catch(t=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${t.message}`)),D("\u041A\u043E\u0440\u0437\u0438\u043D\u0430 \u043E\u0447\u0438\u0449\u0435\u043D\u0430."))}async function a2(e){if(s.mediaLibrary.trashMode)return;let t=await IL({title:"\u0421\u043E\u0437\u0434\u0430\u0442\u044C \u043F\u0430\u043F\u043A\u0443",body:`\u041D\u043E\u0432\u0430\u044F \u043F\u0430\u043F\u043A\u0430 \u0431\u0443\u0434\u0435\u0442 \u0441\u043E\u0437\u0434\u0430\u043D\u0430 \u0432 ${e||"\u043A\u043E\u0440\u043D\u0435 \u043F\u0440\u043E\u0435\u043A\u0442\u0430"}.`,label:"\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u043F\u0430\u043F\u043A\u0438",value:"new-folder",confirmLabel:"\u0421\u043E\u0437\u0434\u0430\u0442\u044C"});if(!t)return;let a=await xn("/api/media/folder",{path:e,name:t});await je(e),s.mediaLibrary.selectedEntry=Pt(a.path),s.mediaLibrary.selectedUrl="",lt(),D(`\u041F\u0430\u043F\u043A\u0430 \u0441\u043E\u0437\u0434\u0430\u043D\u0430: ${a.path}.`)}async function n2(e){if(!e||s.mediaLibrary.trashMode)return;let t=await IL({title:"\u041F\u0435\u0440\u0435\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u0442\u044C",body:e.path,label:"\u041D\u043E\u0432\u043E\u0435 \u0438\u043C\u044F",value:e.name,confirmLabel:"\u041F\u0435\u0440\u0435\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u0442\u044C"});if(!t||t===e.name)return;let a=await xn("/api/media/rename",{path:e.path,name:t});NL(a.replacements),await je(xt(a.path),{selectedUrl:a.url||""});let n=Pt(a.path);n&&(s.mediaLibrary.selectedPath=xt(a.path),s.mediaLibrary.selectedEntry=n,s.mediaLibrary.selectedUrl=n.type==="file"&&n.url||"",lt());let l=Array.isArray(a.updatedFiles)?a.updatedFiles.length:0;D(`\u041F\u0435\u0440\u0435\u0438\u043C\u0435\u043D\u043E\u0432\u0430\u043D\u043E: ${a.path}${l?`. \u0421\u0441\u044B\u043B\u043A\u0438 \u043E\u0431\u043D\u043E\u0432\u043B\u0435\u043D\u044B: ${l}`:""}.`)}async function l2(e){if(!e||s.mediaLibrary.trashMode)return;let t=await xn("/api/media/duplicate",{path:e.path});await je(xt(t.path),{selectedUrl:t.url||""}),await gn().catch(a=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${a.message}`)),t.url||(s.mediaLibrary.selectedEntry=Pt(t.path),s.mediaLibrary.selectedUrl="",lt()),D(`${t.type==="directory"?"\u041F\u0430\u043F\u043A\u0430":"\u0424\u0430\u0439\u043B"} \u043F\u0440\u043E\u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u043D: ${t.path}.`)}async function o2(e){let t=s.mediaLibrary.context;!t||!e||await EL({...t,file:e,afterUpload:async a=>{s.mediaLibrary.selectedUrl=a.url;let n=wa(a.url);await je(xt(n),{selectedUrl:a.url}),await gn().catch(l=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${l.message}`))}})}function r2(){let e=s.mediaLibrary.context;e&&R4({...e,afterUpload:async t=>{s.mediaLibrary.selectedUrl=t.url;let a=wa(t.url);await je(xt(a),{selectedUrl:t.url}),await gn().catch(n=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${n.message}`))}})}async function GL(){let e=qi();if(!e?.trashPath)return;let t=UL(e);await oo({title:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0438\u0437 \u043A\u043E\u0440\u0437\u0438\u043D\u044B \u043D\u0430\u0432\u0441\u0435\u0433\u0434\u0430?",body:"\u042D\u0442\u043E\u0442 \u0444\u0430\u0439\u043B \u0431\u0443\u0434\u0435\u0442 \u0443\u0434\u0430\u043B\u0451\u043D \u043E\u043A\u043E\u043D\u0447\u0430\u0442\u0435\u043B\u044C\u043D\u043E. \u0412\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442\u044C \u0435\u0433\u043E \u0447\u0435\u0440\u0435\u0437 \u0430\u0434\u043C\u0438\u043D\u043A\u0443 \u0443\u0436\u0435 \u043D\u0435 \u043F\u043E\u043B\u0443\u0447\u0438\u0442\u0441\u044F."})&&(await xn("/api/media/trash/delete",{trashPath:e.trashPath}),await Hi({selectedTrashPath:t}),D(`\u0424\u0430\u0439\u043B \u0443\u0434\u0430\u043B\u0451\u043D \u0438\u0437 \u043A\u043E\u0440\u0437\u0438\u043D\u044B \u043D\u0430\u0432\u0441\u0435\u0433\u0434\u0430: ${e.originalPath||e.path}.`))}async function np(){let e=s.mediaLibrary.selectedEntry;if(!e||c.mediaDelete.disabled)return;if(s.mediaLibrary.trashMode){await GL();return}let t=e.type==="file"?s.mediaLibrary.selectedPath||xt(wa(e.url)):xt(e.path),a=UL(e);if(!await oo({title:e.type==="directory"?"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u043F\u0430\u043F\u043A\u0443?":"\u0423\u0434\u0430\u043B\u0438\u0442\u044C unused-\u0444\u0430\u0439\u043B?",body:e.type==="directory"?"\u041F\u0430\u043F\u043A\u0430 \u0431\u0443\u0434\u0435\u0442 \u043F\u0435\u0440\u0435\u043D\u0435\u0441\u0435\u043D\u0430 \u0432 assets/.trash. \u0415\u0441\u043B\u0438 \u0432\u043D\u0443\u0442\u0440\u0438 \u0435\u0441\u0442\u044C \u0444\u0430\u0439\u043B\u044B, \u043A\u043E\u0442\u043E\u0440\u044B\u0435 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u044E\u0442\u0441\u044F \u0432 \u043C\u043E\u0434\u0435\u043B\u0438 \u0438\u043B\u0438 \u0442\u0435\u043A\u0443\u0449\u0435\u0439 \u0432\u0435\u0440\u0441\u0442\u043A\u0435, \u0441\u0435\u0440\u0432\u0435\u0440 \u043E\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442 \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u0435.":"\u0424\u0430\u0439\u043B \u0431\u0443\u0434\u0435\u0442 \u043F\u0435\u0440\u0435\u043D\u0435\u0441\u0451\u043D \u0432 assets/.trash. \u0424\u0430\u0439\u043B\u044B, \u043A\u043E\u0442\u043E\u0440\u044B\u0435 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u044E\u0442\u0441\u044F \u0432 \u043C\u043E\u0434\u0435\u043B\u0438 \u0438\u043B\u0438 \u0442\u0435\u043A\u0443\u0449\u0435\u0439 \u0432\u0435\u0440\u0441\u0442\u043A\u0435, \u0441\u0435\u0440\u0432\u0435\u0440 \u043D\u0435 \u0443\u0434\u0430\u043B\u044F\u0435\u0442."}))return;let l=await xn("/api/media/delete-entry",{path:e.path});await je(t,{selectedUrl:""}),await gn().catch(r=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0440\u0430\u0437\u043C\u0435\u0440\u0430 \u0441\u0430\u0439\u0442\u0430: ${r.message}`));let o=a?Pt(a):null;o&&(s.mediaLibrary.selectedPath=t,s.mediaLibrary.selectedEntry=o,s.mediaLibrary.selectedUrl=o.type==="file"&&o.url||"",lt()),D(`${l.type==="directory"?"\u041F\u0430\u043F\u043A\u0430":"\u0424\u0430\u0439\u043B"} \u043F\u0435\u0440\u0435\u043D\u0435\u0441\u0451\u043D \u0432 ${l.trashPath}.`)}function VL({block:e,editableField:t,grid:a}){let n=fe(e,t.path)??"",l=document.createElement("div"),o=document.createElement("div"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("input"),d=document.createElement("div"),m=document.createElement("div"),f=document.createElement("button"),g=document.createElement("span"),h=document.createElement("input"),v=document.createElement("div"),S=document.createElement("button"),C=document.createElement("button"),x=document.createElement("div"),p=document.createElement("span"),y=document.createElement("span"),L=document.createElement("span"),M=/^(https?:)?\/\//i.test(n)?"url":"file";function E(I){M=I,m.hidden=M!=="file",h.hidden=M!=="url",S.dataset.active=String(M==="file"),C.dataset.active=String(M==="url")}l.className="field-control wide service-media-field",o.className="field-label-row",r.className="field-label-text",r.textContent=t.label||t.path,i.className="field-kind",i.textContent=t.kind||"media",o.append(r,i),u.className="service-media-hidden-input",u.type="hidden",u.dataset.path=t.path,u.value=n,d.className="service-media-control",m.className="service-media-file-control",f.className="service-media-file-button",f.type="button",f.textContent="\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0444\u0430\u0439\u043B",g.className="service-media-file-name",g.textContent=zi(Ca(n),28),g.title=Ca(n),m.append(f,g),h.className="service-media-url-input",h.type="text",h.placeholder="https://...",h.autocomplete="off",h.value=n,v.className="service-media-source-switch",v.setAttribute("aria-label",`${t.label||t.path}: \u0438\u0441\u0442\u043E\u0447\u043D\u0438\u043A`),S.className="service-media-source-button",S.type="button",S.title="\u0424\u0430\u0439\u043B \u0441 \u0434\u0438\u0441\u043A\u0430",S.setAttribute("aria-label","\u0424\u0430\u0439\u043B \u0441 \u0434\u0438\u0441\u043A\u0430"),S.textContent="HD",C.className="service-media-source-button",C.type="button",C.title="\u0412\u043D\u0435\u0448\u043D\u044F\u044F \u0441\u0441\u044B\u043B\u043A\u0430",C.setAttribute("aria-label","\u0412\u043D\u0435\u0448\u043D\u044F\u044F \u0441\u0441\u044B\u043B\u043A\u0430"),C.textContent="URL",v.append(S,C),x.className="service-media-preview",Qm(x,n,y,t),p.className="field-path",p.textContent=`${t.path} -> assets/uploads/${$m(e,t)}`,y.className="media-upload-hint",L.className="media-upload-error",S.addEventListener("click",()=>E("file")),C.addEventListener("click",()=>{E("url"),h.focus()}),h.addEventListener("input",()=>{Wm({block:e,editableField:t,hiddenInput:u,urlInput:h,fileName:g,preview:x,hint:y,value:h.value})}),f.addEventListener("click",()=>{PL({block:e,editableField:t,hiddenInput:u,urlInput:h,fileName:g,preview:x,hint:y,error:L,setSource:E}).catch(I=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043C\u0435\u0434\u0438\u0430\u0442\u0435\u043A\u0438: ${I.message}`))}),E(M),d.append(m,h,v,x),l.append(o,u,d,p,y,L),a.append(l)}function i2(e,t){let a=fe(e,t.path);if(Array.isArray(a))return a;let n=[];return Rt(e,t.path,n),n}function u2(e,t){return e?.adminLabel||e?.title||e?.name||e?.label||e?.question||e?.windowTitle||`\u042D\u043B\u0435\u043C\u0435\u043D\u0442 ${t+1}`}function d2(e){if(e.itemTemplate){let a=at(e.itemTemplate);return e.path==="content.dock.items"&&(a.iconSrc="",a.iconAlt="",a.iconClass=""),a}let t={};for(let a of e.itemFields??[])Rt(t,a.path,a.defaultValue??"");return t}function s2(e,t){let a=String(t||"item").trim()||"item",n=new Set(e.map(o=>o?.id).filter(Boolean));if(!n.has(a))return a;let l=2;for(;n.has(`${a}-${l}`);)l+=1;return`${a}-${l}`}function Kv(e,t){let a=at(t);return Object.prototype.hasOwnProperty.call(a,"id")&&(a.id=s2(e,a.id)),a}function c2(e,t){return`${e?.id||"static-elements"}::${t.path}`}function Yv(e){return String(e||"").normalize("NFKD").replace(/[^\w.-]+/g,"-").replace(/^-+|-+$/g,"").toLowerCase().slice(0,80)}function _d(e,t){if(e&&typeof e=="object"){if(e.id)return`id:${e.id}`;let a=e.targetId||e.href||"",n=Yv(a);if(n)return`item:${n}`;let l=e.title||e.name||e.label||e.question||e.windowTitle||e.adminLabel||"",o=Yv(l);if(o)return`item:${o}`;let r=Uv.get(e);return r||(Hv+=1,r=`runtime:${Hv}`,Uv.set(e,r)),r}return`value:${t}:${String(e)}`}function jn(){let e={};for(let[t,a]of s.collectionOpenState.entries())e[t]=[...a];Jl({collections:e})}function f2(e,t,a){let n=c2(e,t),l=s.collectionOpenState.get(n);return l||(l=new Set,a.length>0&&a.length<=8&&l.add(_d(a[0],0)),s.collectionOpenState.set(n,l),jn()),l}function Vd(e){if(e.type==="checkbox")return e.checked;if(e.dataset.valueType==="number"||e.type==="range"||e.type==="number"){let t=Number.parseFloat(e.value);return Number.isFinite(t)?t:0}return e.value}function Qn(e,t,a){Rt(e,t,Vd(a)),c.json.value=JSON.stringify(e,null,2),me()}function XL({block:e,editableField:t,grid:a}){let n=document.createElement("label"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("input");n.className="field-control boolean-field",l.className="field-label-row",o.className="field-label-text",o.textContent=t.label||t.path,r.className="field-kind",r.textContent=t.kind||"boolean",i.className="field-path",i.textContent=t.path,l.append(o,r),u.dataset.path=t.path,u.type="checkbox",u.checked=!!fe(e,t.path),u.addEventListener("change",()=>{let d=we();d&&Qn(d,t.path,u)}),n.append(l,u,i),a.append(n)}function $v(e,t){let a=Number.parseFloat(t.step??1),n=Number.isFinite(a)&&a>0&&a<1&&String(a).split(".")[1]?.length||0;return`${Number(e).toFixed(n)}${t.suffix||""}`}function KL({block:e,editableField:t,grid:a}){let n=document.createElement("label"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("span"),d=document.createElement("input"),m=document.createElement("span"),f=Number.parseFloat(t.min??0),g=Number.parseFloat(t.max??1),h=Number.parseFloat(t.step??.01),v=Number.parseFloat(fe(e,t.path)),S=Number.isFinite(v)?v:f;n.className="field-control range-field wide",l.className="field-label-row",o.className="field-label-text",o.textContent=t.label||t.path,r.className="field-kind",r.textContent=t.kind||"range",i.className="field-path",i.textContent=t.path,u.className="range-control",m.className="range-value",l.append(o,r),d.dataset.path=t.path,d.dataset.valueType="number",d.type="range",d.min=Number.isFinite(f)?String(f):"0",d.max=Number.isFinite(g)?String(g):"1",d.step=Number.isFinite(h)?String(h):"0.01",d.value=String(S),m.textContent=$v(S,t),d.addEventListener("input",()=>{let C=we();C&&(m.textContent=$v(d.value,t),Qn(C,t.path,d))}),u.append(d,m),n.append(l,u,i),a.append(n)}function YL({block:e,editableField:t,grid:a}){let n=document.createElement("label"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("span"),d=document.createElement("input"),m=document.createElement("span"),f=Number.parseFloat(fe(e,t.path)),g=Number.parseFloat(t.defaultValue??t.min??0),h=Number.isFinite(f)?f:g;n.className="field-control number-field",l.className="field-label-row",o.className="field-label-text",o.textContent=t.label||t.path,r.className="field-kind",r.textContent=t.kind||"number",i.className="field-path",i.textContent=t.path,u.className="number-control",m.className="number-suffix",m.textContent=t.suffix||"",l.append(o,r),d.dataset.path=t.path,d.dataset.valueType="number",d.type="number",d.value=Number.isFinite(h)?String(h):"0",d.autocomplete="off",t.min!=null&&(d.min=String(t.min)),t.max!=null&&(d.max=String(t.max)),t.step!=null&&(d.step=String(t.step)),d.addEventListener("input",()=>{let v=we();v&&Qn(v,t.path,d)}),u.append(d),m.textContent&&u.append(m),n.append(l,u,i),a.append(n)}function Zv(e,t){let a=e.split(".");return a[a.length-1]=t,a.join(".")}function $L({block:e,field:t,grid:a}){let n=document.createElement("div"),l=document.createElement("div"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("input"),u=document.createElement("div"),d=document.createElement("span"),m=Zv(t.path,t.hrefPath||"href"),f=Zv(t.path,t.targetPath||"target"),g=fe(e,t.path)==="href"?"href":"target";function h({mode:v,title:S,inputPath:C,placeholder:x}){let p=document.createElement("label"),y=document.createElement("input"),L=document.createElement("span"),M=document.createElement("input");return p.className="link-mode-row",y.type="checkbox",y.checked=g===v,y.setAttribute("aria-label",`${S}: \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C`),L.textContent=S,M.dataset.path=C,M.type="text",M.autocomplete="off",M.placeholder=x,M.value=fe(e,C)??"",y.addEventListener("change",()=>{if(!y.checked){y.checked=!0;return}let E=we();E&&(i.value=v,Rt(E,t.path,v),u.querySelectorAll('input[type="checkbox"]').forEach(I=>{I.checked=I===y}),c.json.value=JSON.stringify(E,null,2),me(v==="href"?"\u0410\u043A\u0442\u0438\u0432\u0435\u043D \u0432\u043D\u0435\u0448\u043D\u0438\u0439 \u0430\u0434\u0440\u0435\u0441.":"\u0410\u043A\u0442\u0438\u0432\u0435\u043D Target."))}),M.addEventListener("input",()=>{let E=we();E&&Qn(E,C,M)}),p.append(y,L,M),p}n.className="field-control wide link-mode-field",l.className="field-label-row",o.className="field-label-text",o.textContent=t.label||"\u0418\u0441\u0442\u043E\u0447\u043D\u0438\u043A \u0441\u0441\u044B\u043B\u043A\u0438",r.className="field-kind",r.textContent="link",l.append(o,r),i.type="hidden",i.dataset.path=t.path,i.value=g,u.className="link-mode-grid",u.append(h({mode:"href",title:"\u0410\u0434\u0440\u0435\u0441",inputPath:m,placeholder:"https://..."}),h({mode:"target",title:"Target",inputPath:f,placeholder:"index.html#section"})),d.className="field-path",d.textContent=`${t.path} \xB7 ${m} \xB7 ${f}`,n.append(l,i,u,d),a.append(n)}function m2({block:e,editableField:t,head:a}){let n=document.createElement("label"),l=document.createElement("input"),o=document.createElement("span");n.className="group-head-toggle",l.dataset.path=t.path,l.type="checkbox",l.checked=!!fe(e,t.path),o.textContent="\u041E\u0442\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u0435",l.addEventListener("change",()=>{let r=we();r&&Qn(r,t.path,l)}),n.append(l,o),a.append(n)}function p2({block:e,field:t,grid:a}){if(t.kind==="link-mode"){$L({block:e,field:t,grid:a});return}if(t.kind==="boolean"){XL({block:e,editableField:t,grid:a});return}if(t.kind==="range"){KL({block:e,editableField:t,grid:a});return}if(t.kind==="number"){YL({block:e,editableField:t,grid:a});return}let n=document.createElement("label"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=fe(e,t.path)??"",d=t.kind==="html"||t.kind==="textarea",m=d?document.createElement("textarea"):document.createElement("input");n.className=`field-control${d?" wide":""}`,l.className="field-label-row",o.className="field-label-text",o.textContent=t.label||t.path,r.className="field-kind",r.textContent=t.kind||"text",i.className="field-path",i.textContent=t.path,l.append(o,r),m.dataset.path=t.path,m.value=u,d||(m.type="text",m.autocomplete="off"),m.addEventListener("input",()=>{let f=we();f&&Qn(f,t.path,m)}),n.append(l,m,i),a.append(n)}function h2(e,t,a,n,l){if(e.button!==0)return;e.preventDefault(),e.stopPropagation();let o=t.closest(".collection-list");if(!o)return;let r=bL(t),i=LL(t,e);t.classList.add("dragging","sorting-source"),o.classList.add("sorting-active"),t.after(r);let u=f=>{Zm(i,f),SL({event:f,list:o,source:t,placeholder:r,selector:".collection-item-card"})},d=()=>{document.removeEventListener("pointermove",u),document.removeEventListener("pointerup",d),document.removeEventListener("pointercancel",m);let f=CL({list:o,placeholder:r,source:t,selector:".collection-item-card"});if(ba(),f<0||f===n)return;let[g]=a.splice(n,1);a.splice(Math.min(f,a.length),0,g),l("\u041F\u043E\u0440\u044F\u0434\u043E\u043A \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u0438\u0437\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.")},m=()=>{document.removeEventListener("pointermove",u),document.removeEventListener("pointerup",d),document.removeEventListener("pointercancel",m),ba()};document.addEventListener("pointermove",u),document.addEventListener("pointerup",d),document.addEventListener("pointercancel",m)}function g2({block:e,editableField:t,grid:a}){let n=i2(e,t),l=f2(e,t,n),o=document.createElement("section"),r=document.createElement("div"),i=document.createElement("div"),u=document.createElement("button"),d=document.createElement("div");function m(f=null){c.json.value=JSON.stringify(e,null,2),ZL(e),me(f)}o.className="collection-field",r.className="collection-head",i.className="collection-title",i.textContent=t.label||t.path,u.className="collection-add-btn",u.type="button",u.title=`\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u044D\u043B\u0435\u043C\u0435\u043D\u0442 \u0432 \xAB${t.label||t.path}\xBB`,u.setAttribute("aria-label",u.title),u.textContent="+",u.addEventListener("click",()=>{let f=Kv(n,d2(t));n.push(f),l.add(_d(f,n.length-1)),jn(),m(`\u0414\u043E\u0431\u0430\u0432\u043B\u0435\u043D \u044D\u043B\u0435\u043C\u0435\u043D\u0442 \u0432 \xAB${t.label||t.path}\xBB.`)}),r.append(i,u),d.className="collection-list",n.forEach((f,g)=>{let h=_d(f,g),v=document.createElement("details"),S=document.createElement("summary"),C=document.createElement("span"),x=document.createElement("span"),p=document.createElement("button"),y=document.createElement("div"),L=document.createElement("div"),M=f&&typeof f=="object"&&(Object.prototype.hasOwnProperty.call(f,"enabled")||Object.prototype.hasOwnProperty.call(t.itemTemplate??{},"enabled"));if(v.className="collection-item-card",v.classList.toggle("is-hidden",f?.enabled===!1),v.open=l.has(h),v.addEventListener("toggle",()=>{v.open?l.add(h):l.delete(h),jn()}),S.className="collection-summary",C.className="collection-summary-title",C.textContent=u2(f,g),x.className="collection-item-actions",p.className="collection-drag-handle",p.type="button",p.title="\u041F\u0435\u0440\u0435\u0442\u0430\u0449\u0438\u0442\u044C \u044D\u043B\u0435\u043C\u0435\u043D\u0442",p.setAttribute("aria-label","\u041F\u0435\u0440\u0435\u0442\u0430\u0449\u0438\u0442\u044C \u044D\u043B\u0435\u043C\u0435\u043D\u0442"),p.innerHTML='',p.addEventListener("click",E=>{E.preventDefault(),E.stopPropagation()}),p.addEventListener("pointerdown",E=>h2(E,v,n,g,m)),M){Object.prototype.hasOwnProperty.call(f,"enabled")||(f.enabled=!0);let E=document.createElement("span"),I=document.createElement("input"),N=document.createElement("span");E.className="collection-visibility-toggle",E.title="\u0421\u043A\u0440\u044B\u0442\u044C/\u043F\u043E\u043A\u0430\u0437\u0430\u0442\u044C",E.setAttribute("aria-label","\u0421\u043A\u0440\u044B\u0442\u044C/\u043F\u043E\u043A\u0430\u0437\u0430\u0442\u044C"),I.type="checkbox",I.checked=f.enabled!==!1,N.textContent="\u041F\u043E\u043A\u0430\u0437\u0430\u0442\u044C",E.addEventListener("click",A=>A.stopPropagation()),I.addEventListener("click",A=>A.stopPropagation()),I.addEventListener("change",()=>{f.enabled=I.checked,m(I.checked?"\u042D\u043B\u0435\u043C\u0435\u043D\u0442 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u043F\u043E\u043A\u0430\u0437\u0430\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.":"\u042D\u043B\u0435\u043C\u0435\u043D\u0442 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u0441\u043A\u0440\u044B\u0442 \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.")}),E.append(I,N),x.append(E)}[["\u2191","\u041F\u043E\u0434\u043D\u044F\u0442\u044C",()=>{if(g===0)return;let[E]=n.splice(g,1);n.splice(g-1,0,E),jn(),m("\u041F\u043E\u0440\u044F\u0434\u043E\u043A \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u0438\u0437\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.")}],["\u2193","\u041E\u043F\u0443\u0441\u0442\u0438\u0442\u044C",()=>{if(g>=n.length-1)return;let[E]=n.splice(g,1);n.splice(g+1,0,E),jn(),m("\u041F\u043E\u0440\u044F\u0434\u043E\u043A \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u0438\u0437\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.")}],["\u29C9","\u0414\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C",()=>{let E=Kv(n,f);n.splice(g+1,0,E),v.open&&l.add(_d(E,g+1)),jn(),m("\u042D\u043B\u0435\u043C\u0435\u043D\u0442 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u043F\u0440\u043E\u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.")}],[oL,"\u0423\u0434\u0430\u043B\u0438\u0442\u044C",async()=>{await oo()&&(l.delete(h),n.splice(g,1),jn(),m("\u042D\u043B\u0435\u043C\u0435\u043D\u0442 \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438 \u0443\u0434\u0430\u043B\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E."))}]].forEach(([E,I,N])=>{let A=document.createElement("button");A.className="collection-icon-btn",A.type="button",A.title=I,A.setAttribute("aria-label",I),I==="\u0423\u0434\u0430\u043B\u0438\u0442\u044C"?A.innerHTML=E:A.textContent=E,A.addEventListener("click",T=>{T.preventDefault(),T.stopPropagation(),Promise.resolve(N()).catch(B=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044F \u043A\u043E\u043B\u043B\u0435\u043A\u0446\u0438\u0438: ${B.message}`))}),x.append(A)}),x.append(p),S.append(C,x),y.className="collection-item-body",L.className="group-grid";for(let E of t.itemFields??[]){let I={...E,path:`${t.path}.${g}.${E.path}`,label:E.label||E.path,group:t.group};I.kind==="media"?VL({block:e,editableField:I,grid:L}):p2({block:e,field:I,grid:L})}y.append(L),v.append(S,y),d.append(v)}),o.append(r,d),a.append(o)}function ZL(e){if(c.contentFields.innerHTML="",!e.editableFields?.length){let t=document.createElement("div");t.className="empty-note",t.textContent="\u0414\u043B\u044F \u044D\u0442\u043E\u0433\u043E \u0431\u043B\u043E\u043A\u0430 typed-\u043F\u043E\u043B\u044F \u0435\u0449\u0451 \u043D\u0435 \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u044B. \u041F\u043E\u043A\u0430 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u043E \u0440\u0435\u0434\u0430\u043A\u0442\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u0435 \u0447\u0435\u0440\u0435\u0437 JSON.",c.contentFields.append(t);return}for(let[t,a]of T4(e)){let n=document.createElement("section"),l=document.createElement("div"),o=document.createElement("div"),r=document.createElement("h3"),i=document.createElement("p"),u=document.createElement("div");n.className="content-group",l.className="group-head",r.textContent=t,i.className="group-desc",i.textContent=qv[t]||qv.\u041A\u043E\u043D\u0442\u0435\u043D\u0442,o.append(r,i),l.append(o),u.className="group-grid";let d=a.filter(f=>f.kind==="boolean"&&f.headerToggle),m=a.filter(f=>!d.includes(f));d.forEach(f=>m2({block:e,editableField:f,head:l}));for(let f of m){if(f.kind==="collection"){g2({block:e,editableField:f,grid:u});continue}if(f.kind==="media"){VL({block:e,editableField:f,grid:u});continue}if(f.kind==="link-mode"){$L({block:e,field:f,grid:u});continue}if(f.kind==="boolean"){XL({block:e,editableField:f,grid:u});continue}if(f.kind==="range"){KL({block:e,editableField:f,grid:u});continue}if(f.kind==="number"){YL({block:e,editableField:f,grid:u});continue}let g=document.createElement("label"),h=document.createElement("span"),v=document.createElement("span"),S=document.createElement("span"),C=document.createElement("span"),x=fe(e,f.path)??"",p=f.kind==="html"||f.kind==="textarea",y=p?document.createElement("textarea"):document.createElement("input");g.className=`field-control${p?" wide":""}`,h.className="field-label-row",v.className="field-label-text",v.textContent=f.label||f.path,S.className="field-kind",S.textContent=f.kind||"text",C.className="field-path",C.textContent=f.path,h.append(v,S),y.dataset.path=f.path,y.value=x,p||(y.type="text",y.autocomplete="off"),y.addEventListener("input",()=>{let L=we();L&&Qn(L,f.path,y)}),g.append(h,y,C),u.append(g)}n.append(l,u),c.contentFields.append(n)}}function x2(){let e=we();if(e)for(let t of c.contentFields.querySelectorAll("[data-path]"))Rt(e,t.dataset.path,Vd(t))}function y2(){if(!s.selected)return!1;try{let e=JSON.parse(c.json.value);if(s.mode==="seo"&&Ke())s.page.seo=e;else if(Ke())s.page.staticElements=e;else{let t=$n();if(!t)return!1;t.blocks[s.selected.blockIndex]=e}return nt(),me("JSON \u0431\u043B\u043E\u043A\u0430 \u043F\u0440\u0438\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB, \u0447\u0442\u043E\u0431\u044B \u0437\u0430\u043F\u0438\u0441\u0430\u0442\u044C \u0444\u0430\u0439\u043B."),!0}catch(e){return D(`\u041E\u0448\u0438\u0431\u043A\u0430 JSON: ${e.message}`),!1}}function no(){return s.knowledge?(Array.isArray(s.knowledge.tree)||(s.knowledge.tree=[]),s.knowledge.tree):[]}function lp(e=no(),t=null,a=()=>{}){e.forEach((n,l)=>{a(n,t,e,l),lp(Array.isArray(n.children)?n.children:[],n,a)})}function v2(){let e=new Set;return lp(no(),null,t=>{t.id&&e.add(t.id)}),e}function Kn(e){let t=null,a=null,n=null,l=-1;return lp(no(),null,(o,r,i,u)=>{t||o.id!==e||(t=o,a=r,n=i,l=u)}),t?{node:t,parent:a,siblings:n,index:l}:null}function L2(e){return e===_i}function Xd(){return L2(s.knowledgeSelectedId)}function Rm(){return s.knowledge?.title||s.knowledge?.settings?.navTitle||"Knowledge"}function b2(){return Xd()?s.knowledge:Kn(s.knowledgeSelectedId)?.node||null}function S2(e,t="material"){let a={\u0430:"a",\u0431:"b",\u0432:"v",\u0433:"g",\u0434:"d",\u0435:"e",\u0451:"e",\u0436:"zh",\u0437:"z",\u0438:"i",\u0439:"y",\u043A:"k",\u043B:"l",\u043C:"m",\u043D:"n",\u043E:"o",\u043F:"p",\u0440:"r",\u0441:"s",\u0442:"t",\u0443:"u",\u0444:"f",\u0445:"h",\u0446:"c",\u0447:"ch",\u0448:"sh",\u0449:"sch",\u044A:"",\u044B:"y",\u044C:"",\u044D:"e",\u044E:"yu",\u044F:"ya"};return String(e||"").toLowerCase().replace(/[а-яё]/g,l=>a[l]||"").replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||t}function Qv(e,t){let a=t||"material";if(!e.has(a))return a;let n=2;for(;e.has(`${a}-${n}`);)n+=1;return`${a}-${n}`}function C2(e="\u041D\u043E\u0432\u044B\u0439 \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B",t=[]){let a=v2(),n=new Set(t.map(o=>o.slug).filter(Boolean)),l=Qv(n,S2(e));return{id:Qv(a,l),title:e,slug:l,enabled:!0,useContent:!0,seo:{title:e,description:""},bodyHtml:"

\u041D\u043E\u0432\u044B\u0439 \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439.

",children:[]}}function op(){!s.knowledge||Xd()||s.knowledgeSelectedId&&Kn(s.knowledgeSelectedId)||(s.knowledgeSelectedId=_i)}function QL(e){s.knowledgeSelectedId=e,Jl({knowledgeSelectedId:e}),uo()}function w2(){Jl({knowledgeOpenIds:[...s.knowledgeOpenIds]})}function WL(e,t){e&&(t?s.knowledgeOpenIds.add(e):s.knowledgeOpenIds.delete(e),w2())}function rp(e=null){let t=e?Kn(e)?.node:null,a=t?t.children||=[]:no(),n=C2(t?"\u041D\u043E\u0432\u044B\u0439 \u043F\u043E\u0434\u0440\u0430\u0437\u0434\u0435\u043B":"\u041D\u043E\u0432\u044B\u0439 \u0440\u0430\u0437\u0434\u0435\u043B",a);a.push(n),t&&WL(t.id,!0),s.knowledgeSelectedId=n.id,uo(),me("\u041C\u0430\u0442\u0435\u0440\u0438\u0430\u043B \u0434\u043E\u0431\u0430\u0432\u043B\u0435\u043D \u0432 \u0434\u0435\u0440\u0435\u0432\u043E \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439.")}function Wv(e,t){let a=Kn(e);if(!a)return;let n=a.index+t;if(n<0||n>=a.siblings.length)return;let[l]=a.siblings.splice(a.index,1);a.siblings.splice(n,0,l),uo(),me("\u041F\u043E\u0440\u044F\u0434\u043E\u043A \u0434\u0435\u0440\u0435\u0432\u0430 \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439 \u0438\u0437\u043C\u0435\u043D\u0451\u043D.")}async function I2(e){let t=Kn(e);!t||!await oo({title:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B?",body:`\xAB${t.node.title||t.node.id}\xBB \u0438 \u0432\u0441\u0435 \u0432\u043B\u043E\u0436\u0435\u043D\u043D\u044B\u0435 \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B \u0431\u0443\u0434\u0443\u0442 \u0443\u0434\u0430\u043B\u0435\u043D\u044B \u0438\u0437 \u0434\u0435\u0440\u0435\u0432\u0430.`})||(t.siblings.splice(t.index,1),s.knowledgeSelectedId===e&&(s.knowledgeSelectedId=t.siblings[Math.min(t.index,t.siblings.length-1)]?.id||t.parent?.id||_i),uo(),me("\u041C\u0430\u0442\u0435\u0440\u0438\u0430\u043B \u0443\u0434\u0430\u043B\u0451\u043D \u0438\u0437 \u0434\u0435\u0440\u0435\u0432\u0430 \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439."))}function JL(e,t=0){let a=document.createElement("div"),n=document.createElement("div"),l=document.createElement("button"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("span"),d=document.createElement("span"),m=Array.isArray(e.children)?e.children:[],f=m.length>0,g=s.knowledgeOpenIds.has(e.id)||e.id===s.knowledgeSelectedId||m.some(h=>h.id===s.knowledgeSelectedId);if(a.className="knowledge-tree-item",a.style.setProperty("--depth",String(t)),n.className="knowledge-tree-row",n.dataset.active=String(e.id===s.knowledgeSelectedId),n.dataset.disabled=String(e.enabled===!1),l.className="knowledge-tree-select",l.type="button",o.className="knowledge-tree-icon",o.textContent=f?g?"\u25BE":"\u203A":e.useContent===!1?"G":"A",r.className="knowledge-tree-copy",i.className="knowledge-tree-title",i.textContent=e.title||e.id,u.className="knowledge-tree-meta",u.textContent=e.useContent===!1?"\u0433\u0440\u0443\u043F\u043F\u0430":f?"\u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430 + \u0432\u0435\u0442\u043A\u0430":"\u0441\u0442\u0430\u0442\u044C\u044F",r.append(i,u),l.append(o,r),l.addEventListener("click",()=>{f&&WL(e.id,!g),QL(e.id)}),d.className="knowledge-tree-actions",[["+","\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0434\u043E\u0447\u0435\u0440\u043D\u0438\u0439 \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B",()=>rp(e.id)],["\u2191","\u041F\u043E\u0434\u043D\u044F\u0442\u044C",()=>Wv(e.id,-1)],["\u2193","\u041E\u043F\u0443\u0441\u0442\u0438\u0442\u044C",()=>Wv(e.id,1)],[oL,"\u0423\u0434\u0430\u043B\u0438\u0442\u044C",()=>I2(e.id)]].forEach(([h,v,S])=>{let C=document.createElement("button");C.type="button",C.className="knowledge-tree-action",C.title=v,C.setAttribute("aria-label",v),v==="\u0423\u0434\u0430\u043B\u0438\u0442\u044C"?C.innerHTML=h:C.textContent=h,C.addEventListener("click",x=>{x.stopPropagation(),Promise.resolve(S()).catch(p=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0434\u0435\u0440\u0435\u0432\u0430: ${p.message}`))}),d.append(C)}),n.append(l,d),a.append(n),f&&g){let h=document.createElement("div");h.className="knowledge-tree-children",m.forEach(v=>h.append(JL(v,t+1))),a.append(h)}return a}function k2(){let e=document.createElement("div"),t=document.createElement("div"),a=document.createElement("button"),n=document.createElement("span"),l=document.createElement("span"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("button");return e.className="knowledge-tree-item knowledge-root-item",e.style.setProperty("--depth","0"),t.className="knowledge-tree-row",t.dataset.active=String(Xd()),t.dataset.disabled="false",a.className="knowledge-tree-select",a.type="button",n.className="knowledge-tree-icon",n.textContent="K",l.className="knowledge-tree-copy",o.className="knowledge-tree-title",o.textContent=Rm(),r.className="knowledge-tree-meta",r.textContent="/knowledge/ \u0433\u043B\u0430\u0432\u043D\u0430\u044F",l.append(o,r),a.append(n,l),a.addEventListener("click",()=>QL(_i)),i.className="knowledge-tree-actions",u.type="button",u.className="knowledge-tree-action",u.title="\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0440\u0430\u0437\u0434\u0435\u043B \u0432 \u043A\u043E\u0440\u0435\u043D\u044C",u.setAttribute("aria-label","\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0440\u0430\u0437\u0434\u0435\u043B \u0432 \u043A\u043E\u0440\u0435\u043D\u044C"),u.textContent="+",u.addEventListener("click",d=>{d.stopPropagation(),rp(null)}),i.append(u),t.append(a,i),e.append(t),e}function Kd(){c.regions.innerHTML="";let e=document.createElement("section"),t=document.createElement("h2"),a=document.createElement("div");if(e.className="region-group knowledge-region",t.className="region-title",t.textContent="\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439",a.className="knowledge-tree",a.append(k2()),no().length)no().forEach(n=>a.append(JL(n)));else{let n=document.createElement("div");n.className="empty-note knowledge-empty-tree",n.textContent="\u0414\u0435\u0440\u0435\u0432\u043E \u043F\u0443\u0441\u0442\u043E\u0435. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \u043F\u043B\u044E\u0441 \u0441\u0432\u0435\u0440\u0445\u0443, \u0447\u0442\u043E\u0431\u044B \u0434\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u043F\u0435\u0440\u0432\u044B\u0439 \u0440\u0430\u0437\u0434\u0435\u043B.",a.append(n)}e.append(t,a),c.regions.append(e)}function eb(e,t,a,n="\u041C\u0430\u0442\u0435\u0440\u0438\u0430\u043B \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439 \u043E\u0431\u043D\u043E\u0432\u043B\u0451\u043D."){Rt(e,t,a),me(n)}function Ut({node:e,path:t,label:a,kind:n="text",wide:l=!1,placeholder:o=""}){let r=document.createElement("label"),i=document.createElement("span"),u=document.createElement("span"),d=document.createElement("span"),m=n==="textarea"?document.createElement("textarea"):document.createElement("input"),f=document.createElement("span");return r.className=`field-control${l||n==="textarea"?" wide":""}`,i.className="field-label-row",u.className="field-label-text",u.textContent=a,d.className="field-kind",d.textContent=n,m.value=fe(e,t)??"",m.placeholder=o,m.dataset.knowledgePath=t,m.tagName==="INPUT"&&(m.type=n==="url"?"url":"text",m.autocomplete="off"),m.addEventListener("input",()=>{eb(e,t,m.value),(t==="title"||t==="settings.navTitle")&&Kd()}),f.className="field-path",f.textContent=t,i.append(u,d),r.append(i,m,f),r}function Im({node:e,path:t,label:a,checkedDefault:n=!0}){let l=document.createElement("label"),o=document.createElement("span"),r=document.createElement("span"),i=document.createElement("span"),u=document.createElement("input"),d=document.createElement("span");l.className="field-control boolean-field",o.className="field-label-row",r.className="field-label-text",r.textContent=a,i.className="field-kind",i.textContent="boolean",u.type="checkbox";let m=fe(e,t);return u.checked=m==null?n:m!==!1,u.addEventListener("change",()=>{eb(e,t,u.checked),lb(),Kd()}),d.className="field-path",d.textContent=t,o.append(r,i),l.append(o,u,d),l}function Bm(e,t){if(!e||!t)return!1;let a=t.nodeType===Node.ELEMENT_NODE?t:t.parentElement;return!!(a&&e.contains(a))}function Xn(){let e=window.getSelection();if(!e?.rangeCount)return;let t=c.knowledgeForm.querySelector("[data-knowledge-richtext]");!Bm(t,e.anchorNode)||!Bm(t,e.focusNode)||(s.knowledgeSavedSelection=e.getRangeAt(0).cloneRange())}function tb(e){e.focus();let t=s.knowledgeSavedSelection;(!t||!Bm(e,t.commonAncestorContainer))&&(t=document.createRange(),t.selectNodeContents(e),t.collapse(!1),s.knowledgeSavedSelection=t.cloneRange());let a=window.getSelection();return a.removeAllRanges(),a.addRange(t),t}function ip(e,t){Rt(e,t.dataset.knowledgeBodyPath||"bodyHtml",t.innerHTML.trim()),me("\u0422\u0435\u043A\u0441\u0442 \u0441\u0442\u0430\u0442\u044C\u0438 \u043E\u0431\u043D\u043E\u0432\u043B\u0451\u043D.")}function pn(e,t,a,n=null){tb(e),document.execCommand(a,!1,n),ip(t,e)}function ab(e,t,a){tb(e),document.execCommand("insertHTML",!1,a),Xn(),ip(t,e)}function Rd(e){return String(e??"").replace(/\s+/g," ").trim().replaceAll("&","&").replaceAll('"',""").replaceAll("[","(").replaceAll("]",")")}function nb(e){return String(e||"").trim().replace(/^#+/,"").replace(/^index\.html#/i,"").replace(/^\/?#/,"")}function Yd(e){return(String(e??"").trim()||"/").replace(/^\/+(https?:\/\/)/i,"$1").replace(/^\/+((?:mailto|tel):)/i,"$1")}function E2({name:e,link:t,target:a,blockId:n}){let l=Rd(e||"\u041F\u043E\u0441\u043C\u043E\u0442\u0440\u0435\u0442\u044C"),o=Rd(Yd(t)),r=nb(a),i=String(n||"").trim(),u=i?` block="${Rd(i)}"`:"",d=r?` target="${Rd(r)}"`:"";return`[button name="${l}" link="${o}"${u}${d}]`}function M2(){if(!c.knowledgeButtonTargetOptions)return;c.knowledgeButtonTargetOptions.innerHTML="";let e=new Set;for(let{id:t,label:a,target:n}of Vn()){let l=n.toLowerCase();if(!e.has(l)){let r=document.createElement("option");r.value=n,r.label=`${a} / ${t}`,c.knowledgeButtonTargetOptions.append(r),e.add(l)}let o=String(t||"").toLowerCase();if(t&&!e.has(o)){let r=document.createElement("option");r.value=t,r.label=`${a} / block id`,c.knowledgeButtonTargetOptions.append(r),e.add(o)}}}function up(e=""){c.knowledgeButtonError&&(c.knowledgeButtonError.textContent=e)}function io(e=null){let t=s.knowledgeButtonResolve;s.knowledgeButtonResolve=null,c.knowledgeButtonModal.classList.add("hidden"),up(""),t&&t(e)}function _m(){let e=c.knowledgeButtonName.value.trim();if(!e){up("\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u043A\u043D\u043E\u043F\u043A\u0438 \u043E\u0431\u044F\u0437\u0430\u0442\u0435\u043B\u044C\u043D\u043E."),c.knowledgeButtonName.focus();return}let t=Yd(c.knowledgeButtonLink.value);c.knowledgeButtonLink.value=t,io({name:e,link:t,targetInput:c.knowledgeButtonTarget.value.trim()})}function A2({name:e="\u041F\u043E\u0441\u043C\u043E\u0442\u0440\u0435\u0442\u044C \u0434\u0435\u043C\u043E",link:t="/",target:a=""}={}){return s.knowledgeButtonResolve&&io(null),new Promise(n=>{s.knowledgeButtonResolve=n,M2(),up(""),c.knowledgeButtonName.value=e,c.knowledgeButtonLink.value=Yd(t),c.knowledgeButtonTarget.value=nb(a),c.knowledgeButtonModal.classList.remove("hidden"),c.knowledgeButtonName.focus(),c.knowledgeButtonName.select()})}function D2(e,t){Xn();let a={value:""},n={textContent:"",title:""},l=document.createElement("div"),o=document.createElement("span"),r=document.createElement("span"),i={value:""};PL({block:{id:t.id||"knowledge"},editableField:{path:"content.bodyHtml",label:"\u0418\u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u0435 \u0441\u0442\u0430\u0442\u044C\u0438"},hiddenInput:a,urlInput:i,fileName:n,preview:l,hint:o,error:r,setSource(){},onSelect(u){let d=String(u||"");d&&ab(e,t,``)}}).catch(u=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043C\u0435\u0434\u0438\u0430\u0442\u0435\u043A\u0438: ${u.message}`))}function T2(e,t){let a=document.createElement("div");return a.className="knowledge-rich-toolbar",[["P","\u0410\u0431\u0437\u0430\u0446",()=>pn(e,t,"formatBlock","P")],["H2","\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A H2",()=>pn(e,t,"formatBlock","H2")],["H3","\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A H3",()=>pn(e,t,"formatBlock","H3")],["B","\u0416\u0438\u0440\u043D\u044B\u0439",()=>pn(e,t,"bold")],["I","\u041A\u0443\u0440\u0441\u0438\u0432",()=>pn(e,t,"italic")],["UL","\u0421\u043F\u0438\u0441\u043E\u043A",()=>pn(e,t,"insertUnorderedList")],["OL","\u041D\u0443\u043C\u0435\u0440\u043E\u0432\u0430\u043D\u043D\u044B\u0439 \u0441\u043F\u0438\u0441\u043E\u043A",()=>pn(e,t,"insertOrderedList")],["Link","\u0421\u0441\u044B\u043B\u043A\u0430",()=>{let l=window.prompt("\u0410\u0434\u0440\u0435\u0441 \u0441\u0441\u044B\u043B\u043A\u0438","/knowledge/");l&&pn(e,t,"createLink",l)}],["Button","\u041A\u043D\u043E\u043F\u043A\u0430",async()=>{Xn();let l=await A2();if(!l)return;let o=l.targetInput,r=r4(o),i=r?r.target:o,u=r?.id||"";ab(e,t,`

${Ri(E2({name:l.name,link:l.link,target:i,blockId:u}))}

`)}],["Image","\u0418\u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u0435",()=>D2(e,t)]].forEach(([l,o,r])=>{let i=document.createElement("button");i.type="button",i.textContent=l,i.title=o,i.addEventListener("mousedown",u=>u.preventDefault()),i.addEventListener("click",r),a.append(i)}),a}function lb(){let e=Xd(),t=b2();if(c.empty.classList.add("hidden"),c.form.classList.add("hidden"),c.projectSettingsForm.classList.add("hidden"),c.knowledgeForm.classList.remove("hidden"),c.knowledgeForm.innerHTML="",!s.knowledge){c.knowledgeForm.innerHTML='
\u0417\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043C \u0431\u0430\u0437\u0443 \u0437\u043D\u0430\u043D\u0438\u0439...
';return}if(!t){let y=document.createElement("section");y.className="content-panel",y.innerHTML='

\u0414\u0435\u0440\u0435\u0432\u043E \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439 \u043F\u0443\u0441\u0442\u043E\u0435

\u041D\u0430\u0436\u043C\u0438\u0442\u0435 \u043F\u043B\u044E\u0441 \u0432 \u043B\u0435\u0432\u043E\u043C \u0432\u0435\u0440\u0445\u043D\u0435\u043C \u0443\u0433\u043B\u0443, \u0447\u0442\u043E\u0431\u044B \u0441\u043E\u0437\u0434\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u044B\u0439 \u0440\u0430\u0437\u0434\u0435\u043B.

',c.knowledgeForm.append(y);return}s.knowledge.settings||={},s.knowledge.seo||={},s.knowledge.seo.title||(s.knowledge.seo.title=s.knowledge.title||"Knowledge"),!s.knowledge.seo.description&&s.knowledge.settings.description&&(s.knowledge.seo.description=s.knowledge.settings.description);let a=e?"introHtml":"bodyHtml",l=(e?null:Kn(t.id))?.parent?.title||s.knowledge.title||"\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439";c.selectedRegion.textContent=e?`NODE.DC / ${Rm()} / /knowledge/`:`NODE.DC / ${s.knowledge.title||"\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439"} / ${l}`,c.selectedTitle.textContent=e?Rm():t.title||"\u041C\u0430\u0442\u0435\u0440\u0438\u0430\u043B";let o=document.createElement("section"),r=document.createElement("div"),i=document.createElement("h3"),u=document.createElement("div"),d=document.createElement("div");o.className="content-panel",r.className="panel-head",u.className="section-kicker",u.textContent=e?"\u041A\u043E\u0440\u043D\u0435\u0432\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430":"\u0423\u0437\u0435\u043B \u0434\u0435\u0440\u0435\u0432\u0430",i.textContent=e?"\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 /knowledge/":"\u041F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u044B \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u0430",r.append(Object.assign(document.createElement("div"),{innerHTML:`${u.outerHTML}

${i.textContent}

`})),d.className="group-grid",e?d.append(Ut({node:t,path:"title",label:"H1 / \u043D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u0432 sidebar",wide:!1}),Ut({node:t,path:"settings.navTitle",label:"\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u0432 \u0448\u0430\u043F\u043A\u0435",wide:!1}),Ut({node:t,path:"settings.searchPlaceholder",label:"Placeholder \u043F\u043E\u0438\u0441\u043A\u0430",wide:!1}),Ut({node:t,path:"settings.homeHref",label:"\u0421\u0441\u044B\u043B\u043A\u0430 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u0430",kind:"url",wide:!1}),Ut({node:t,path:"settings.themeDefault",label:"\u0422\u0435\u043C\u0430 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E",wide:!1}),Im({node:t,path:"settings.downloadEnabled",label:"\u041F\u043E\u043A\u0430\u0437\u044B\u0432\u0430\u0442\u044C Download",checkedDefault:!1})):d.append(Ut({node:t,path:"title",label:"\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435",wide:!1}),Ut({node:t,path:"slug",label:"Slug",wide:!1}),Im({node:t,path:"enabled",label:"\u041F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u0442\u044C"}),Im({node:t,path:"useContent",label:"\u0418\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C \u043A\u0430\u043A \u0438\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0438\u043E\u043D\u043D\u0443\u044E \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0443"})),o.append(r,d);let m=document.createElement("section"),f=document.createElement("div"),g=document.createElement("div");m.className="content-panel",f.className="panel-head",f.innerHTML=`
SEO

${e?"\u0421\u043D\u0438\u043F\u043F\u0435\u0442 \u0440\u0430\u0437\u0434\u0435\u043B\u0430":"\u0421\u043D\u0438\u043F\u043F\u0435\u0442 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B"}

\u041F\u043E\u043B\u044F \u043F\u043E\u043F\u0430\u0434\u0443\u0442 \u0432 title, description, Open Graph \u0438 sitemap.`,g.className="group-grid",e?g.append(Ut({node:t,path:"seo.title",label:"SEO title",wide:!0}),Ut({node:t,path:"seo.description",label:"SEO description / \u043E\u043F\u0438\u0441\u0430\u043D\u0438\u0435",kind:"textarea",wide:!0})):(t.seo||={},g.append(Ut({node:t,path:"seo.title",label:"SEO title",wide:!0}),Ut({node:t,path:"seo.description",label:"SEO description",kind:"textarea",wide:!0}))),m.append(f,g);let h=document.createElement("section"),v=document.createElement("div"),S=document.createElement("div");if(h.className="content-panel knowledge-rich-panel",v.className="panel-head",v.innerHTML=`
\u041A\u043E\u043D\u0442\u0435\u043D\u0442

${e?"\u0422\u0435\u043A\u0441\u0442 \u0433\u043B\u0430\u0432\u043D\u043E\u0439 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B":"\u0422\u0435\u043A\u0441\u0442 \u0441\u0442\u0430\u0442\u044C\u0438"}

H2/H3 \u0444\u043E\u0440\u043C\u0438\u0440\u0443\u044E\u0442 \u043F\u0440\u0430\u0432\u044B\u0439 \u0441\u043F\u0438\u0441\u043E\u043A \u201C\u041D\u0430 \u044D\u0442\u043E\u0439 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0435\u201D.`,S.className="knowledge-rich-editor",S.contentEditable=e||t.useContent!==!1?"true":"false",S.dataset.knowledgeRichtext="true",S.dataset.knowledgeBodyPath=a,S.innerHTML=fe(t,a)||"

",S.addEventListener("focusout",()=>Xn()),S.addEventListener("keyup",()=>Xn()),S.addEventListener("mouseup",()=>Xn()),S.addEventListener("input",()=>ip(t,S)),h.append(v,T2(S,t),S),!e&&t.useContent===!1){let y=document.createElement("p");y.className="group-desc",y.textContent="\u041A\u043E\u043D\u0442\u0435\u043D\u0442 \u0441\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u0441\u044F \u0432 \u043C\u043E\u0434\u0435\u043B\u0438, \u043D\u043E \u043F\u0443\u0431\u043B\u0438\u0447\u043D\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430 \u0434\u043B\u044F \u044D\u0442\u043E\u0433\u043E \u0443\u0437\u043B\u0430 \u043D\u0435 \u0431\u0443\u0434\u0435\u0442 \u0433\u0435\u043D\u0435\u0440\u0438\u0440\u043E\u0432\u0430\u0442\u044C\u0441\u044F, \u043F\u043E\u043A\u0430 \u0444\u043B\u0430\u0433 \u0432\u044B\u043A\u043B\u044E\u0447\u0435\u043D.",h.append(y)}let C=document.createElement("details");C.className="json-details knowledge-json",C.innerHTML=`${e?"JSON \u0432\u0441\u0435\u0439 \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439":"JSON \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0433\u043E \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u0430"}`;let x=document.createElement("label"),p=document.createElement("textarea");x.className="json-field",p.value=JSON.stringify(t,null,2),p.addEventListener("blur",()=>{try{let y=JSON.parse(p.value);if(e)s.knowledge=y,s.knowledgeSelectedId=_i;else{let L=Kn(t.id);if(!L)return;L.siblings[L.index]=y,s.knowledgeSelectedId=y.id||t.id}uo(),me(e?"JSON \u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439 \u043F\u0440\u0438\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.":"JSON \u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u0430 \u043F\u0440\u0438\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.")}catch(y){D(`\u041E\u0448\u0438\u0431\u043A\u0430 JSON ${e?"\u0431\u0430\u0437\u044B \u0437\u043D\u0430\u043D\u0438\u0439":"\u043C\u0430\u0442\u0435\u0440\u0438\u0430\u043B\u0430"}: ${y.message}`)}}),x.innerHTML="\u0422\u0435\u0445\u043D\u0438\u0447\u0435\u0441\u043A\u043E\u0435 \u043F\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043B\u0435\u043D\u0438\u0435",x.append(p),C.append(x),c.knowledgeForm.append(o,m,h,C)}function uo(){eo(),op(),Kd(),lb()}async function dp(){if(!Yn()){Fd();return}let e=await Me("/api/knowledge");s.knowledge=await Sa(e,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0431\u0430\u0437\u0443 \u0437\u043D\u0430\u043D\u0438\u0439"),s.knowledgeSelectedId=lo().knowledgeSelectedId||s.knowledgeSelectedId||null,op(),nt(),Ia(!1),D("\u041C\u043E\u0434\u0435\u043B\u044C knowledge.json \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043D\u0430.")}async function ob(){let e=await Me("/api/knowledge",{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(s.knowledge)});if(!e.ok)throw new Error(await e.text())}async function N2(){await ob(),Ia(!1),D("\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0430 \u0432 content/knowledge.json.")}async function R2(){await ob();let e=await Me("/api/render/knowledge",{method:"POST"}),t=await e.json();if(!e.ok||!t.ok)throw new Error(t.error||"Render failed");Ia(!1),D(`${t.stdout?`\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0430. ${t.stdout}`:"\u0411\u0430\u0437\u0430 \u0437\u043D\u0430\u043D\u0438\u0439 \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0430 \u0438 \u043F\u0435\u0440\u0435\u0441\u043E\u0431\u0440\u0430\u043D\u0430."}${jm(t)}`)}async function rb(){let e=await Oi();if(s.projectConfig=e,s.knowledge=null,!Yn()){s.page=null,s.templates=[],s.selected=null,Fd(),D("\u0421\u0430\u0439\u0442 \u043D\u0435 \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043D \u0432 \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u044B\u0439 workspace CMS.");return}let[t,a]=await Promise.all([Me("/api/page/home"),Me("/api/block-templates/home")]);s.page=await Sa(t,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C home.json"),s.templates=await Sa(a,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u044B \u0431\u043B\u043E\u043A\u043E\u0432"),f4(),m4(),Jw(),s.selected={kind:"static"},nt(),Ia(!1),D("\u041C\u043E\u0434\u0435\u043B\u044C home.json \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043D\u0430."),s.mode==="knowledge"&&!s.knowledge&&await dp()}async function ib(){we()&&Tm(),i4();let e=await Me("/api/page/home",{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(s.page)});if(!e.ok)throw new Error(await e.text())}async function B2(){await ib(),Ia(!1),D("\u041C\u043E\u0434\u0435\u043B\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0430 \u0432 content/pages/home.json. \u0414\u043B\u044F \u043F\u0443\u0431\u043B\u0438\u0447\u043D\u043E\u0439 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B \u043D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C index.html\xBB.")}async function _2(){await ib();let e=await Me("/api/render/home",{method:"POST"}),t=await e.json();if(!e.ok||!t.ok)throw new Error(t.error||"Render failed");Ia(!1),D(`${t.stdout?`\u041C\u043E\u0434\u0435\u043B\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0430. ${t.stdout}`:"\u041C\u043E\u0434\u0435\u043B\u044C \u0441\u043E\u0445\u0440\u0430\u043D\u0435\u043D\u0430, index.html \u043F\u0435\u0440\u0435\u0441\u043E\u0431\u0440\u0430\u043D."}${jm(t)}`)}function ub(e){if(Ke())return;let t=$n(),a=s.selected?.blockIndex;if(!t||a==null)return;let n=a+e;if(n<0||n>=t.blocks.length)return;let[l]=t.blocks.splice(a,1);t.blocks.splice(n,0,l),s.selected.blockIndex=n,nt(),me("\u041F\u043E\u0440\u044F\u0434\u043E\u043A \u0431\u043B\u043E\u043A\u043E\u0432 \u0438\u0437\u043C\u0435\u043D\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB \u0438\u043B\u0438 \xAB\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C index.html\xBB.")}function O2(){if(Ke())return;let e=$n(),t=we();if(!e||!t)return;let a=at(t);a.id=Xm(t.id),a.adminLabel=`${t.adminLabel||t.id} \u2014 \u043A\u043E\u043F\u0438\u044F`,a.anchor&&(a.anchor=Vm(a.anchor,a)),a.scopeIds=!0,e.blocks.splice(s.selected.blockIndex+1,0,a),s.selected.blockIndex+=1,nt(),me(`\u0411\u043B\u043E\u043A \xAB${a.adminLabel||a.id}\xBB \u043F\u0440\u043E\u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.`)}function z2(){if(Ke())return;let e=we();e&&(s.clipboard=at(e),D(`\u0421\u043A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u043D \u0431\u043B\u043E\u043A: ${e.adminLabel||e.id}`))}function q2(){if(Ke())return;let e=$n();if(!e||!s.clipboard)return;let t=at(s.clipboard);t.id=Xm(t.id),t.adminLabel=`${t.adminLabel||t.id} \u2014 \u0432\u0441\u0442\u0430\u0432\u043A\u0430`,t.anchor&&(t.anchor=Vm(t.anchor,t)),t.scopeIds=!0,e.blocks.splice(s.selected.blockIndex+1,0,t),s.selected.blockIndex+=1,nt(),me(`\u0411\u043B\u043E\u043A \xAB${t.adminLabel||t.id}\xBB \u0432\u0441\u0442\u0430\u0432\u043B\u0435\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E.`)}async function U2(){if(Ke())return;let e=$n();!e||s.selected.blockIndex==null||!await oo()||(e.blocks.splice(s.selected.blockIndex,1),s.selected.blockIndex=Math.min(s.selected.blockIndex,e.blocks.length-1),s.selected.blockIndex<0&&(s.selected={kind:"static"}),nt(),me("\u0411\u043B\u043E\u043A \u0443\u0434\u0430\u043B\u0451\u043D \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E. \u041D\u0430\u0436\u043C\u0438\u0442\u0435 \xAB\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C \u043C\u043E\u0434\u0435\u043B\u044C\xBB \u0438\u043B\u0438 \xAB\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C index.html\xBB."))}function H2(){s.selected={kind:"project-settings"},nt()}var Jv,Ud,Od,tL,_i,s,zm,qm,zw,Um,qw,Uw,c,Ne,qv,nL,Hm,Hw,lL,oL,hn,Uv,Hv,o4,db=hb(()=>{Jv=window.location.pathname.match(/^\/s\/[a-z][a-z0-9-]*/)?.[0]||"",Ud=e=>`${Jv}/${String(e).replace(/^\.?\//,"")}`;Od=[];document.querySelector("#site-selector").addEventListener("change",e=>{eL()?window.location.assign(`/s/${e.target.value}/`):e.target.value=s.projectConfig.id});document.querySelectorAll("[data-close-dialog]").forEach(e=>e.addEventListener("click",()=>e.closest("dialog").close()));document.querySelector("#new-site-form").addEventListener("submit",async e=>{e.preventDefault();let t=e.submitter;t.disabled=!0;try{if(!eL())return;let a=Object.fromEntries(new FormData(e.target)),n=await fetch("/api/sites",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(a)}),l=await Sa(n,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0441\u043E\u0437\u0434\u0430\u0442\u044C \u0441\u0430\u0439\u0442");window.location.assign(`/s/${l.project.id}/`)}catch(a){document.querySelector("#new-site-error").textContent=a.message}finally{t.disabled=!1}});document.querySelector("#transfer-site-form").addEventListener("submit",async e=>{e.preventDefault();let t=e.submitter;t.disabled=!0;try{if(s.projectConfigDirty)throw new Error("\u0421\u043D\u0430\u0447\u0430\u043B\u0430 \u0441\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u0435 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u0442\u0435\u043A\u0443\u0449\u0435\u0433\u043E \u043F\u0440\u043E\u0435\u043A\u0442\u0430");let a=await fetch(`/api/sites/${s.projectConfig.id}/deploy-transfer`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({fromSiteId:document.querySelector("#transfer-site-source").value})});await Sa(a,"\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043F\u0435\u0440\u0435\u043D\u0435\u0441\u0442\u0438 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438"),await Oi(),Zn(),document.querySelector("#transfer-site-dialog").close(),D("\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0435\u0440\u0435\u043D\u0435\u0441\u0435\u043D\u044B. \u041E\u0431\u0430 \u0441\u0430\u0439\u0442\u0430 \u043F\u043E\u043A\u0430 \u043D\u0435 \u043F\u0443\u0431\u043B\u0438\u043A\u0443\u044E\u0442\u0441\u044F. \u0412\u043A\u043B\u044E\u0447\u0438\u0442\u0435 \u0434\u0435\u043F\u043B\u043E\u0439 \u043F\u043E\u043B\u0443\u0447\u0430\u0442\u0435\u043B\u044F \u043F\u043E\u0441\u043B\u0435 \u043F\u0440\u043E\u0432\u0435\u0440\u043A\u0438.")}catch(a){document.querySelector("#transfer-site-error").textContent=a.message}finally{t.disabled=!1}});tL=Jv+"nodedc-admin-layout-v1",_i="__knowledge-root__";s={mode:Ow(),page:null,projectConfig:null,projectConfigDirty:!1,keepSiteArchiveBackup:!0,publishJob:null,publishResumeAttempted:!1,knowledge:null,knowledgeSelectedId:null,knowledgeSavedSelection:null,knowledgeOpenIds:new Set(lo().knowledgeOpenIds||[]),templates:[],selected:null,clipboard:null,drag:null,dragTarget:null,dirty:!1,filePickerActive:!1,mediaUploadActive:!1,filePickerResetTimer:null,deleteConfirmResolve:null,mediaActionResolve:null,knowledgeButtonResolve:null,collectionOpenState:_w(),mediaLibrary:{columns:[],context:null,contextMenu:null,trashMode:!1,previousPath:"",selectedPath:"",selectedEntry:null,selectedUrl:"",root:"",kind:"all",query:"",loaded:!1,dragEntryPath:"",lastPath:aL()}},zm="sections",qm="\u0421\u0435\u043A\u0446\u0438\u0438",zw={title:"NODE.DC - \u043F\u043B\u0430\u0442\u0444\u043E\u0440\u043C\u0430 \u0434\u043B\u044F \u043F\u0440\u043E\u0446\u0435\u0441\u0441\u043E\u0432, \u0434\u0430\u043D\u043D\u044B\u0445 \u0438 \u0418\u0418-\u0430\u0433\u0435\u043D\u0442\u043E\u0432",description:"NODE.DC \u043E\u0431\u044A\u0435\u0434\u0438\u043D\u044F\u0435\u0442 Hub, Engine, Ops, \u043F\u0440\u0438\u043A\u043B\u0430\u0434\u043D\u044B\u0435 \u043C\u043E\u0434\u0443\u043B\u0438 \u0438 \u0441\u043A\u0432\u043E\u0437\u043D\u043E\u0433\u043E \u0430\u0441\u0441\u0438\u0441\u0442\u0435\u043D\u0442\u0430 \u0434\u043B\u044F \u0437\u0430\u0434\u0430\u0447, workflow, \u0434\u0430\u043D\u043D\u044B\u0445, \u0440\u043E\u043B\u0435\u0439, \u0438\u043D\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0439 \u0438 \u0438\u043D\u0436\u0435\u043D\u0435\u0440\u043D\u044B\u0445 \u043C\u043E\u0434\u0435\u043B\u0435\u0439.",canonicalUrl:"https://nodedc.dctouch.ru/",robots:"index,follow,max-image-preview:large",siteName:"NODE.DC",locale:"ru_RU",ogImage:"https://nodedc.dctouch.ru/assets/site/images/69b6acdde3123ef078e2b7f3_og-img.jpg",imageAlt:"NODE.DC - \u043F\u043B\u0430\u0442\u0444\u043E\u0440\u043C\u0430 \u0434\u043B\u044F \u043F\u0440\u043E\u0446\u0435\u0441\u0441\u043E\u0432, \u0434\u0430\u043D\u043D\u044B\u0445 \u0438 \u0418\u0418-\u0430\u0433\u0435\u043D\u0442\u043E\u0432",organizationName:"DCTOUCH",organizationUrl:"https://dctouch.ru/",applicationCategory:"BusinessApplication"},Um={targetCluster:"",searchIntent:"",primaryQuery:"",secondaryQueries:"",title:"",description:"",coverageNotes:"",indexHint:"section"},qw=[{path:"seo.title",label:"Title \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B",kind:"text",group:"\u0421\u043D\u0438\u043F\u043F\u0435\u0442",min:35,max:70},{path:"seo.description",label:"Description \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u044B",kind:"textarea",group:"\u0421\u043D\u0438\u043F\u043F\u0435\u0442",min:110,max:170},{path:"seo.canonicalUrl",label:"Canonical URL",kind:"url",group:"\u0418\u043D\u0434\u0435\u043A\u0441\u0430\u0446\u0438\u044F"},{path:"seo.robots",label:"Robots meta",kind:"select",group:"\u0418\u043D\u0434\u0435\u043A\u0441\u0430\u0446\u0438\u044F",options:["index,follow,max-image-preview:large","noindex,nofollow","index,follow"]},{path:"seo.siteName",label:"Site name",kind:"text",group:"Open Graph"},{path:"seo.locale",label:"Locale",kind:"text",group:"Open Graph"},{path:"seo.ogImage",label:"OG image",kind:"url",group:"Open Graph"},{path:"seo.imageAlt",label:"OG image alt",kind:"textarea",group:"Open Graph",min:20,max:120},{path:"seo.organizationName",label:"Organization",kind:"text",group:"Schema.org"},{path:"seo.organizationUrl",label:"Organization URL",kind:"url",group:"Schema.org"},{path:"seo.applicationCategory",label:"Application category",kind:"text",group:"Schema.org"}],Uw=[{path:"seo.targetCluster",label:"\u041A\u043B\u0430\u0441\u0442\u0435\u0440",kind:"text",group:"\u0421\u0435\u043C\u0430\u043D\u0442\u0438\u043A\u0430"},{path:"seo.searchIntent",label:"\u0418\u043D\u0442\u0435\u043D\u0442",kind:"textarea",group:"\u0421\u0435\u043C\u0430\u043D\u0442\u0438\u043A\u0430",min:20,max:220},{path:"seo.primaryQuery",label:"\u041E\u0441\u043D\u043E\u0432\u043D\u043E\u0439 \u0437\u0430\u043F\u0440\u043E\u0441",kind:"text",group:"\u0421\u0435\u043C\u0430\u043D\u0442\u0438\u043A\u0430"},{path:"seo.secondaryQueries",label:"\u0421\u043C\u0435\u0436\u043D\u044B\u0435 \u0437\u0430\u043F\u0440\u043E\u0441\u044B",kind:"textarea",group:"\u0421\u0435\u043C\u0430\u043D\u0442\u0438\u043A\u0430"},{path:"seo.title",label:"SEO-\u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u0431\u043B\u043E\u043A\u0430",kind:"text",group:"\u0421\u043D\u0438\u043F\u043F\u0435\u0442 \u0431\u043B\u043E\u043A\u0430",min:35,max:80},{path:"seo.description",label:"SEO-\u043E\u043F\u0438\u0441\u0430\u043D\u0438\u0435 \u0431\u043B\u043E\u043A\u0430",kind:"textarea",group:"\u0421\u043D\u0438\u043F\u043F\u0435\u0442 \u0431\u043B\u043E\u043A\u0430",min:90,max:180},{path:"seo.indexHint",label:"\u0420\u043E\u043B\u044C \u0432 \u0438\u043D\u0434\u0435\u043A\u0441\u0430\u0446\u0438\u0438",kind:"select",group:"\u0418\u043D\u0434\u0435\u043A\u0441\u0430\u0446\u0438\u044F",options:["section","supporting","conversion","noindex"]},{path:"seo.coverageNotes",label:"\u0417\u0430\u043C\u0435\u0442\u043A\u0438 \u043F\u043E \u043E\u0445\u0432\u0430\u0442\u0443",kind:"textarea",group:"\u0410\u043D\u0430\u043B\u0438\u0442\u0438\u043A\u0430",min:20,max:500}],c={modeContent:document.querySelector("#admin-mode-content"),modeSeo:document.querySelector("#admin-mode-seo"),modeKnowledge:document.querySelector("#admin-mode-knowledge"),modeNav:document.querySelector(".nodedc-expanded-nav-group"),sidebarTitle:document.querySelector("#sidebar-title"),workspaceName:document.querySelector("#workspace-name"),workspaceRole:document.querySelector("#workspace-role"),editorHeading:document.querySelector("#editor-heading"),panelKicker:document.querySelector("#content-panel-kicker"),panelTitle:document.querySelector("#content-panel-title"),panelNote:document.querySelector("#content-panel-note"),regions:document.querySelector("#regions"),addProject:document.querySelector("#add-project"),projectSettings:document.querySelector("#project-settings"),addBlock:document.querySelector("#add-block"),reload:document.querySelector("#reload"),save:document.querySelector("#save"),render:document.querySelector("#render"),publish:document.querySelector("#publish"),dirtyState:document.querySelector("#dirty-state"),status:document.querySelector("#status"),empty:document.querySelector("#empty-state"),form:document.querySelector("#block-form"),knowledgeForm:document.querySelector("#knowledge-form"),projectSettingsForm:document.querySelector("#project-settings-form"),selectedRegion:document.querySelector("#selected-region"),selectedTitle:document.querySelector("#selected-title"),id:document.querySelector("#block-id"),label:document.querySelector("#block-label"),template:document.querySelector("#block-template"),anchor:document.querySelector("#block-anchor"),targetOptions:document.querySelector("#block-target-options"),enabled:document.querySelector("#block-enabled"),contentFields:document.querySelector("#content-fields"),json:document.querySelector("#block-json"),moveUp:document.querySelector("#move-up"),moveDown:document.querySelector("#move-down"),duplicate:document.querySelector("#duplicate"),copy:document.querySelector("#copy"),pasteAfter:document.querySelector("#paste-after"),deleteBlock:document.querySelector("#delete-block"),templateModal:document.querySelector("#template-modal"),templateList:document.querySelector("#template-list"),templateModalClose:document.querySelector("#template-modal-close"),templateModalCancel:document.querySelector("#template-modal-cancel"),deleteModal:document.querySelector("#delete-modal"),deleteModalTitle:document.querySelector("#delete-modal-title"),deleteModalBody:document.querySelector("#delete-modal-body"),deleteModalCancel:document.querySelector("#delete-modal-cancel"),deleteModalConfirm:document.querySelector("#delete-modal-confirm"),mediaModal:document.querySelector("#media-modal"),mediaModalTitle:document.querySelector("#media-modal-title"),mediaModalSubtitle:document.querySelector("#media-modal-subtitle"),mediaSiteSize:document.querySelector("#media-site-size"),mediaModalClose:document.querySelector("#media-modal-close"),mediaModalCancel:document.querySelector("#media-modal-cancel"),mediaTrashToggle:document.querySelector("#media-trash-toggle"),mediaSearch:document.querySelector("#media-search"),mediaKindFilters:document.querySelector("#media-kind-filters"),mediaRootFilters:document.querySelector("#media-root-filters"),mediaUpload:document.querySelector("#media-upload"),mediaRefresh:document.querySelector("#media-refresh"),mediaDropZone:document.querySelector("#media-drop-zone"),mediaBreadcrumbs:document.querySelector("#media-breadcrumbs"),mediaList:document.querySelector("#media-list"),mediaEmpty:document.querySelector("#media-empty"),mediaPreview:document.querySelector("#media-preview"),mediaPreviewName:document.querySelector("#media-preview-name"),mediaPreviewPath:document.querySelector("#media-preview-path"),mediaPreviewMeta:document.querySelector("#media-preview-meta"),mediaPreviewUsage:document.querySelector("#media-preview-usage"),mediaSelect:document.querySelector("#media-select"),mediaDelete:document.querySelector("#media-delete"),mediaContextMenu:document.querySelector("#media-context-menu"),mediaActionModal:document.querySelector("#media-action-modal"),mediaActionTitle:document.querySelector("#media-action-title"),mediaActionBody:document.querySelector("#media-action-body"),mediaActionLabel:document.querySelector("#media-action-label"),mediaActionInput:document.querySelector("#media-action-input"),mediaActionCancel:document.querySelector("#media-action-cancel"),mediaActionConfirm:document.querySelector("#media-action-confirm"),knowledgeButtonModal:document.querySelector("#knowledge-button-modal"),knowledgeButtonClose:document.querySelector("#knowledge-button-close"),knowledgeButtonName:document.querySelector("#knowledge-button-name"),knowledgeButtonLink:document.querySelector("#knowledge-button-link"),knowledgeButtonTarget:document.querySelector("#knowledge-button-target"),knowledgeButtonTargetOptions:document.querySelector("#knowledge-button-target-options"),knowledgeButtonError:document.querySelector("#knowledge-button-error"),knowledgeButtonCancel:document.querySelector("#knowledge-button-cancel"),knowledgeButtonConfirm:document.querySelector("#knowledge-button-confirm")},Ne={id:"static-elements",type:"staticElements",adminLabel:"\u0421\u0442\u0430\u0442\u0438\u0447\u043D\u044B\u0435 \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",enabled:!0,content:{navigation:{logoSrc:"./assets/site/images/69ad964d951f9d17cc5a919e_logo-app.svg",logoAlt:"\u0433\u043B\u0430\u0432\u043D\u0430\u044F",brandLabel:"NODE.DC",links:[{enabled:!0,label:"\u041E \u043F\u0440\u043E\u0434\u0443\u043A\u0442\u0435",href:"",target:"index.html#platform-composition",linkMode:"target",linkTarget:""},{enabled:!0,label:"\u041B\u0438\u0441\u0442 \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u044F",href:"",target:"index.html#hero",linkMode:"target",linkTarget:""},{enabled:!0,label:"\u0414\u043E\u043A\u0443\u043C\u0435\u043D\u0442\u0430\u0446\u0438\u044F",href:"https://nodedc.dctouch.ru/",target:"",linkMode:"href",linkTarget:"_blank"},{enabled:!0,label:"\u0422\u0430\u0440\u0438\u0444\u044B",href:"",target:"index.html#pricing-intro",linkMode:"target",linkTarget:""}]},notifications:[{enabled:!0,eyebrowHtml:'\u0414\u0410\u041B\u0415\u0415 \u2014 \u0418\u042E\u041B\u042C 2026',eyebrowClass:"red-txt gray",title:"\u041E\u0442\u043A\u0440\u044B\u0442\u0430\u044F \u0431\u0435\u0442\u0430",body:"\u041E\u0442\u043A\u0440\u044B\u0432\u0430\u0435\u043C \u0434\u043E\u0441\u0442\u0443\u043F \u0432\u0441\u0435\u043C. \u0411\u0443\u0434\u0435\u043C \u0441\u043E\u0431\u0438\u0440\u0430\u0442\u044C \u0438 \u043E\u0442\u043B\u0430\u0436\u0438\u0432\u0430\u0442\u044C \u0432\u043C\u0435\u0441\u0442\u0435."},{enabled:!0,eyebrowHtml:'\u0414\u0410\u041B\u0415\u0415 \u2014 \u0418\u042E\u041B\u042C 2026',eyebrowClass:"red-txt gray",title:"\u0410\u043B\u044C\u0444\u0430 \u0434\u043B\u044F Founder-\u0434\u043E\u0441\u0442\u0443\u043F\u0430",body:"\u041D\u0430 \u0432\u0442\u043E\u0440\u043E\u0439 \u0444\u0430\u0437\u0435 \u0442\u0435\u0441\u0442\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u044F \u0431\u0435\u0442\u0430 \u043E\u0442\u043A\u0440\u044B\u0442\u0430 \u0434\u043B\u044F \u0432\u0441\u0435\u0445 \u043F\u043E\u0434\u043F\u0438\u0441\u0447\u0438\u043A\u043E\u0432 Founder-\u0442\u0430\u0440\u0438\u0444\u0430."},{enabled:!0,eyebrowHtml:"\u0421\u0415\u0419\u0427\u0410\u0421",eyebrowClass:"red-txt",title:"\u0418\u043D\u0432\u0430\u0439\u0442\u044B \u0432 \u0437\u0430\u043A\u0440\u044B\u0442\u0443\u044E \u0431\u0435\u0442\u0443 \u0443\u0436\u0435 \u043E\u0442\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u044B.",body:"\u0421\u0435\u0439\u0447\u0430\u0441 \u0442\u0435\u0441\u0442\u0438\u0440\u0443\u0435\u043C \u0431\u0430\u0437\u043E\u0432\u0443\u044E \u0444\u0443\u043D\u043A\u0446\u0438\u043E\u043D\u0430\u043B\u044C\u043D\u043E\u0441\u0442\u044C \u0438 \u0418\u0418-\u0438\u043D\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044E. "}],dock:{items:[{enabled:!0,title:"NODE.DC",href:"javascript:void(0)",linkTarget:"",targetId:"app-data",iconSrc:"./assets/site/images/69ad964d951f9d17cc5a919e_logo-app.svg",iconAlt:"\u0418\u043A\u043E\u043D\u043A\u0430 NODE.DC",className:"dock-icon nodedc-app",iconClass:"logo",dividerBefore:!1},{enabled:!0,title:"\u041A\u043E\u0440\u0437\u0438\u043D\u0430",href:"javascript:void(0)",linkTarget:"",targetId:"",iconSrc:"./assets/site/images/69a9ae818a76c773dc3cf7bc_trash.avif",iconAlt:"\u0411\u0435\u043B\u0430\u044F \u0438\u043A\u043E\u043D\u043A\u0430 \u043A\u043E\u0440\u0437\u0438\u043D\u044B.",className:"dock-icon no-bg",iconClass:"dock-app-img trash",dividerBefore:!0}],demoFileLabel:"\u0434\u0435\u043C\u043E-\u0432\u0438\u0434\u0435\u043E.txt"},assets:{webglModelSrc:"./assets/custom/icon.glb",logoPng:"./assets/uploads/images/Logo/dclogo_white_alpha-mqus5if2.png",logoPngAlt:"\u041B\u043E\u0433\u043E\u0442\u0438\u043F NODE.DC",appIconSrc:"./assets/site/images/69ad964d951f9d17cc5a919e_logo-app.svg",appIconAlt:"\u0418\u043A\u043E\u043D\u043A\u0430 NODE.DC",appWordmarkSrc:"./assets/site/images/69ad96a28b06b7552a339137_logtype.svg?v=node-dc",appWordmarkAlt:"\u041B\u043E\u0433\u043E\u0442\u0438\u043F NODE.DC",faviconSvg:"./assets/uploads/favicon/icon-adaptive.svg",faviconIco:"./assets/uploads/favicon/favicon.ico",faviconAppleTouchIcon:"./assets/uploads/favicon/apple-touch-icon.png",faviconPng192:"./assets/uploads/favicon/icon-192.png",faviconPng512:"./assets/uploads/favicon/icon-512.png",faviconManifest:"./assets/uploads/favicon/manifest.webmanifest.json"}},editableFields:[Z("content.navigation.logoSrc","\u041B\u043E\u0433\u043E\u0442\u0438\u043F \u0432 \u0448\u0430\u043F\u043A\u0435","media","attr","\u0428\u0430\u043F\u043A\u0430: \u043B\u043E\u0433\u043E\u0442\u0438\u043F"),Z("content.navigation.logoAlt","\u041B\u043E\u0433\u043E\u0442\u0438\u043F \u0432 \u0448\u0430\u043F\u043A\u0435: alt","text","text","\u0428\u0430\u043F\u043A\u0430: \u043B\u043E\u0433\u043E\u0442\u0438\u043F"),Z("content.navigation.brandLabel","\u0411\u0440\u0435\u043D\u0434 \u0432 \u0448\u0430\u043F\u043A\u0435","text","text","\u0428\u0430\u043F\u043A\u0430: \u043B\u043E\u0433\u043E\u0442\u0438\u043F"),Cm("content.navigation.links","\u041A\u043D\u043E\u043F\u043A\u0438 \u0448\u0430\u043F\u043A\u0438","\u0428\u0430\u043F\u043A\u0430: \u0441\u0441\u044B\u043B\u043A\u0438",{enabled:!0,label:"\u041D\u043E\u0432\u0430\u044F \u0441\u0441\u044B\u043B\u043A\u0430",href:"",target:"index.html#",linkMode:"target",linkTarget:""},[Z("label","\u0422\u0435\u043A\u0441\u0442 \u043A\u043D\u043E\u043F\u043A\u0438","text","text","\u0428\u0430\u043F\u043A\u0430: \u0441\u0441\u044B\u043B\u043A\u0438"),Z("linkMode","\u0418\u0441\u0442\u043E\u0447\u043D\u0438\u043A \u0441\u0441\u044B\u043B\u043A\u0438","link-mode","attr","\u0428\u0430\u043F\u043A\u0430: \u0441\u0441\u044B\u043B\u043A\u0438")]),Cm("content.notifications","\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F","\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F",{enabled:!0,eyebrowHtml:"\u0421\u0415\u0419\u0427\u0410\u0421",eyebrowClass:"red-txt gray",title:"\u041D\u043E\u0432\u043E\u0435 \u0443\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u0435",body:"\u0422\u0435\u043A\u0441\u0442 \u0443\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F."},[Z("eyebrowHtml","\u0414\u0430\u0442\u0430 / \u0441\u0442\u0430\u0442\u0443\u0441","html","html","\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F"),Z("eyebrowClass","CSS-\u043A\u043B\u0430\u0441\u0441 \u0441\u0442\u0430\u0442\u0443\u0441\u0430","text","attr","\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F"),Z("title","\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A","text","text","\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F"),Z("body","\u0422\u0435\u043A\u0441\u0442","textarea","text","\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F")]),Cm("content.dock.items","\u0418\u043A\u043E\u043D\u043A\u0438 dock-\u043F\u0430\u043D\u0435\u043B\u0438","Dock",{enabled:!0,title:"\u041D\u043E\u0432\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435",href:"javascript:void(0)",linkTarget:"",targetId:"",iconSrc:"",iconAlt:"",className:"dock-icon nodedc-app",iconClass:"",dividerBefore:!1},[Z("enabled","\u041E\u0442\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u0435","boolean","boolean","Dock"),Z("title","\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435","text","text","Dock"),Z("href","\u0421\u0441\u044B\u043B\u043A\u0430 / \u0430\u0434\u0440\u0435\u0441","url","attr","Dock"),Z("linkTarget","Target \u0441\u0441\u044B\u043B\u043A\u0438","text","attr","Dock"),Z("targetId","ID \u043E\u043A\u043D\u0430 / \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u044F","text","attr","Dock"),Z("iconSrc","\u0418\u043A\u043E\u043D\u043A\u0430","media","attr","Dock"),Z("iconAlt","Alt \u0438\u043A\u043E\u043D\u043A\u0438","text","text","Dock"),Z("dividerBefore","\u0420\u0430\u0437\u0434\u0435\u043B\u0438\u0442\u0435\u043B\u044C \u0441\u043B\u0435\u0432\u0430","boolean","boolean","Dock")]),Z("content.dock.demoFileLabel","Dock: \u043F\u043E\u0434\u043F\u0438\u0441\u044C \u0434\u0435\u043C\u043E-\u0444\u0430\u0439\u043B\u0430","text","text","Dock"),Z("content.assets.webglModelSrc","WebGL-\u043C\u043E\u0434\u0435\u043B\u044C \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u0430","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.logoPng","PNG-\u043B\u043E\u0433\u043E\u0442\u0438\u043F","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.logoPngAlt","PNG-\u043B\u043E\u0433\u043E\u0442\u0438\u043F: alt","text","text","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.appIconSrc","\u0418\u043A\u043E\u043D\u043A\u0430 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u044F","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.appIconAlt","\u0418\u043A\u043E\u043D\u043A\u0430 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u044F: alt","text","text","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.appWordmarkSrc","Wordmark \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u044F","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.appWordmarkAlt","Wordmark \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u044F: alt","text","text","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.faviconSvg","Favicon SVG","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.faviconIco","Favicon ICO","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.faviconAppleTouchIcon","Favicon Apple 180","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.faviconPng192","Favicon PNG 192","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.faviconPng512","Favicon PNG 512","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B"),Z("content.assets.faviconManifest","Favicon manifest","media","attr","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B")]},qv={"\u0428\u0430\u043F\u043A\u0430: \u043B\u043E\u0433\u043E\u0442\u0438\u043F":"\u0421\u0442\u0430\u0442\u0438\u0447\u043D\u044B\u0439 \u0437\u043D\u0430\u043A \u0432\u0435\u0440\u0445\u043D\u0435\u0439 mac-\u043F\u0430\u043D\u0435\u043B\u0438: \u0444\u0430\u0439\u043B \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u0430, alt \u0438 \u0431\u0440\u0435\u043D\u0434\u043E\u0432\u0430\u044F \u043F\u043E\u0434\u043F\u0438\u0441\u044C.","\u0428\u0430\u043F\u043A\u0430: \u0441\u0441\u044B\u043B\u043A\u0438":"\u041F\u0443\u043D\u043A\u0442\u044B \u043D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438 \u0432\u0435\u0440\u0445\u043D\u0435\u0439 mac-\u043F\u0430\u043D\u0435\u043B\u0438. \u041A\u0430\u0436\u0434\u044B\u0439 \u043F\u0443\u043D\u043A\u0442 \u043C\u043E\u0436\u043D\u043E \u0434\u043E\u0431\u0430\u0432\u0438\u0442\u044C, \u0443\u0434\u0430\u043B\u0438\u0442\u044C \u0438 \u043F\u0435\u0440\u0435\u0441\u0442\u0430\u0432\u0438\u0442\u044C.",\u0423\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u044F:"\u041A\u0430\u0440\u0442\u043E\u0447\u043A\u0438 \u0443\u0432\u0435\u0434\u043E\u043C\u043B\u0435\u043D\u0438\u0439 \u0441\u043F\u0440\u0430\u0432\u0430 \u0441\u0432\u0435\u0440\u0445\u0443. \u041F\u043E\u0440\u044F\u0434\u043E\u043A \u0432 \u0430\u0434\u043C\u0438\u043D\u043A\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u043F\u043E\u0440\u044F\u0434\u043A\u0443 \u043D\u0430 \u0441\u0430\u0439\u0442\u0435.",Dock:"\u041D\u0438\u0436\u043D\u044F\u044F \u0441\u0438\u0441\u0442\u0435\u043C\u043D\u0430\u044F \u043F\u0430\u043D\u0435\u043B\u044C: \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u044F, \u043A\u043E\u0440\u0437\u0438\u043D\u0430, \u0441\u0441\u044B\u043B\u043A\u0438 \u0438 \u043F\u043E\u0434\u043F\u0438\u0441\u0438 \u0444\u0430\u0439\u043B\u043E\u0432.","\u041C\u043E\u0434\u0435\u043B\u044C \u0438 \u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B":"\u0411\u0430\u0437\u043E\u0432\u044B\u0435 \u0430\u0441\u0441\u0435\u0442\u044B \u0441\u0442\u0430\u0442\u0438\u0447\u043D\u043E\u0433\u043E \u0441\u043B\u043E\u044F: GLB-\u043C\u043E\u0434\u0435\u043B\u044C, PNG/SVG-\u043B\u043E\u0433\u043E\u0442\u0438\u043F\u044B, favicon-\u043A\u043E\u043C\u043F\u043B\u0435\u043A\u0442 \u0438 alt-\u0442\u0435\u043A\u0441\u0442\u044B.",\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A:"\u0413\u043B\u0430\u0432\u043D\u044B\u0439 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u0438 \u0432\u0432\u043E\u0434\u043D\u044B\u0439 \u0442\u0435\u043A\u0441\u0442 \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0439 \u0441\u0435\u043A\u0446\u0438\u0438.","\u0412\u0435\u0440\u0445\u043D\u0438\u0439 \u0438\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0438\u043E\u043D\u043D\u044B\u0439 \u0431\u043B\u043E\u043A":"\u0412\u0435\u0440\u0445\u043D\u044F\u044F \u043F\u0430\u0440\u0430: \u0434\u043B\u0438\u043D\u043D\u044B\u0439 \u0442\u0435\u043A\u0441\u0442 \u0438 \u043A\u0440\u0443\u043F\u043D\u044B\u0439 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043D\u0430\u0434 \u043C\u0435\u0434\u0438\u0430\u0441\u043B\u0430\u0439\u0434\u0435\u0440\u043E\u043C.","\u041D\u0438\u0436\u043D\u0438\u0439 \u0438\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0438\u043E\u043D\u043D\u044B\u0439 \u0431\u043B\u043E\u043A":"\u041D\u0438\u0436\u043D\u044F\u044F \u0437\u0435\u0440\u043A\u0430\u043B\u044C\u043D\u0430\u044F \u043F\u0430\u0440\u0430: \u043A\u0440\u0443\u043F\u043D\u044B\u0439 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u0438 \u0434\u043B\u0438\u043D\u043D\u044B\u0439 \u0442\u0435\u043A\u0441\u0442 \u043F\u043E\u0434 \u043C\u0435\u0434\u0438\u0430\u0441\u043B\u0430\u0439\u0434\u0435\u0440\u043E\u043C.","\u0422\u0435\u0437\u0438\u0441\u044B \u043F\u0435\u0440\u0432\u043E\u0433\u043E \u044D\u043A\u0440\u0430\u043D\u0430":"\u0427\u0435\u0442\u044B\u0440\u0435 \u0441\u043C\u044B\u0441\u043B\u043E\u0432\u044B\u0445 \u0442\u0435\u0437\u0438\u0441\u0430 \u0432\u043E\u043A\u0440\u0443\u0433 \u0444\u043E\u0440\u043C\u044B \u0440\u0430\u043D\u043D\u0435\u0433\u043E \u0434\u043E\u0441\u0442\u0443\u043F\u0430.","\u041A\u0430\u0440\u0442\u043E\u0447\u043A\u0430 \u0434\u043E\u0441\u0442\u0443\u043F\u0430":"\u0415\u0434\u0438\u043D\u044B\u0439 \u043A\u043E\u043C\u043F\u043E\u043D\u0435\u043D\u0442 \u043E\u043A\u043D\u0430 \u0437\u0430\u044F\u0432\u043A\u0438: \u0440\u0435\u0434\u0430\u043A\u0442\u0438\u0440\u0443\u0435\u0442\u0441\u044F \u0437\u0434\u0435\u0441\u044C \u0438 \u043F\u043E\u0432\u0442\u043E\u0440\u044F\u0435\u0442\u0441\u044F \u0432 \u043D\u0438\u0436\u043D\u0435\u043C \u0431\u043B\u043E\u043A\u0435 \u0437\u0430\u043F\u0440\u043E\u0441\u0430 DEMO.",\u0424\u043E\u0440\u043C\u0430:"\u041F\u043B\u0435\u0439\u0441\u0445\u043E\u043B\u0434\u0435\u0440\u044B, \u043A\u043D\u043E\u043F\u043A\u0438, success/failure \u0441\u043E\u0441\u0442\u043E\u044F\u043D\u0438\u044F \u0444\u043E\u0440\u043C\u044B.","\u042E\u0440\u0438\u0434\u0438\u0447\u0435\u0441\u043A\u0438\u0439 \u0431\u043B\u043E\u043A":"\u041F\u043E\u043B\u0438\u0442\u0438\u043A\u0438, \u043F\u0440\u0430\u0432\u0430 \u0438 \u043D\u0438\u0436\u043D\u0438\u0439 \u0442\u0435\u043A\u0441\u0442 \u0444\u043E\u0440\u043C\u044B.","\u0412\u0438\u0434\u0435\u043E-\u043E\u043A\u043D\u043E":"\u041E\u043A\u043D\u043E \u0434\u0435\u043C\u043E-\u0432\u0438\u0434\u0435\u043E \u0438 \u043F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u043D\u044B\u0439 \u043C\u0435\u0434\u0438\u0430-\u0444\u0430\u0439\u043B.",\u041F\u0443\u043D\u043A\u0442\u044B:"\u0422\u0435\u043A\u0441\u0442\u043E\u0432\u044B\u0435 \u043F\u0443\u043D\u043A\u0442\u044B \u0432\u043D\u0443\u0442\u0440\u0438 \u0441\u0435\u043A\u0446\u0438\u0438.",\u0421\u043B\u0430\u0439\u0434\u0435\u0440:"\u0412\u0438\u0434\u0435\u043E-\u043F\u0440\u0435\u0432\u044C\u044E \u0438 \u043F\u043E\u0434\u043F\u0438\u0441\u0438 \u043A\u0430\u0440\u0442\u043E\u0447\u0435\u043A \u0432\u043D\u0443\u0442\u0440\u0438 \u0433\u043E\u0440\u0438\u0437\u043E\u043D\u0442\u0430\u043B\u044C\u043D\u043E\u0433\u043E \u0441\u043B\u0430\u0439\u0434\u0435\u0440\u0430.",\u0421\u043A\u0440\u043E\u043B\u043B:"\u0421\u043A\u043E\u0440\u043E\u0441\u0442\u044C \u043B\u043E\u043A\u0430\u043B\u044C\u043D\u043E\u0439 \u043F\u0440\u043E\u043A\u0440\u0443\u0442\u043A\u0438 \u0432\u043D\u0443\u0442\u0440\u0438 \u0431\u043B\u043E\u043A\u0430: \u043C\u0435\u043D\u044C\u0448\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u2014 \u0441\u043F\u043E\u043A\u043E\u0439\u043D\u0435\u0435 \u0448\u0430\u0433, \u0431\u043E\u043B\u044C\u0448\u0435 \u2014 \u0431\u044B\u0441\u0442\u0440\u0435\u0435.","\u041E\u0434\u0438\u043D \u043A\u043B\u0438\u043A":"\u041F\u043E\u0434\u0431\u043B\u043E\u043A \u043F\u0440\u043E \u0431\u044B\u0441\u0442\u0440\u043E\u0435 \u0434\u043E\u0431\u0430\u0432\u043B\u0435\u043D\u0438\u0435 \u0438 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0443 \u043A\u043E\u043C\u043F\u043E\u043D\u0435\u043D\u0442\u043E\u0432.",MCP:"\u041F\u043E\u0434\u0431\u043B\u043E\u043A \u043F\u0440\u043E MCP-\u0441\u0435\u0440\u0432\u0435\u0440 \u0438 \u043A\u043E\u043D\u0442\u0435\u043A\u0441\u0442 NODE.DC.","\u041E\u043A\u043D\u043E FAQ":"\u041D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u043E\u043A\u043D\u0430 FAQ \u0438 \u0441\u043B\u0443\u0436\u0435\u0431\u043D\u044B\u0435 \u043F\u043E\u0434\u043F\u0438\u0441\u0438 mail-\u0438\u043D\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430.",\u041E\u0442\u043F\u0440\u0430\u0432\u0438\u0442\u0435\u043B\u044C:"\u041F\u0440\u043E\u0444\u0438\u043B\u044C \u043E\u0442\u043F\u0440\u0430\u0432\u0438\u0442\u0435\u043B\u044F \u0432 FAQ: \u0430\u0432\u0430\u0442\u0430\u0440, \u0438\u043C\u044F \u0438 \u043F\u043E\u0434\u043F\u0438\u0441\u0438 \u043F\u0438\u0441\u044C\u043C\u0430.",FAQ:"\u0412\u043E\u043F\u0440\u043E\u0441\u044B \u0438 \u043E\u0442\u0432\u0435\u0442\u044B mail-\u0438\u043D\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430. \u041A\u0430\u0436\u0434\u044B\u0439 \u043F\u0443\u043D\u043A\u0442 \u043C\u043E\u0436\u043D\u043E \u0434\u043E\u0431\u0430\u0432\u0438\u0442\u044C, \u0443\u0434\u0430\u043B\u0438\u0442\u044C \u0438 \u043F\u0435\u0440\u0435\u0441\u0442\u0430\u0432\u0438\u0442\u044C.",CTA:"\u0424\u0438\u043D\u0430\u043B\u044C\u043D\u044B\u0439 \u043F\u0440\u0438\u0437\u044B\u0432 \u043A \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044E: \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A, \u043F\u043E\u044F\u0441\u043D\u0435\u043D\u0438\u0435, \u043A\u043D\u043E\u043F\u043A\u0430 \u0438 \u0441\u0441\u044B\u043B\u043A\u0430.","\u0426\u0435\u043D\u0442\u0440\u0430\u043B\u044C\u043D\u044B\u0439 \u0442\u0435\u043A\u0441\u0442":"\u041E\u0442\u0434\u0435\u043B\u044C\u043D\u044B\u0439 \u0446\u0435\u043D\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u043D\u043D\u044B\u0439 \u0442\u0435\u043A\u0441\u0442\u043E\u0432\u044B\u0439 \u0431\u043B\u043E\u043A: \u043D\u0430\u0434\u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A, \u043A\u0440\u0443\u043F\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430 \u0438 \u0442\u0440\u0438 \u043F\u043E\u0434\u043F\u0438\u0441\u0438.",\u0422\u0430\u0440\u0438\u0444\u044B:"\u041E\u043A\u043D\u043E \u0442\u0430\u0440\u0438\u0444\u043D\u043E\u0439 \u0442\u0430\u0431\u043B\u0438\u0446\u044B: \u043F\u043B\u0430\u043D\u044B, \u0446\u0435\u043D\u044B, \u043A\u043D\u043E\u043F\u043A\u0438 \u0438 \u043F\u0440\u0438\u043C\u0435\u0447\u0430\u043D\u0438\u044F.","\u0421\u0442\u0440\u043E\u043A\u0438 \u0442\u0430\u0440\u0438\u0444\u043E\u0432":"\u041F\u043E\u0432\u0442\u043E\u0440\u044F\u0435\u043C\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438 \u0442\u0430\u0440\u0438\u0444\u043D\u043E\u0439 \u0442\u0430\u0431\u043B\u0438\u0446\u044B \u0438 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u044F \u043F\u043E \u043A\u0430\u0436\u0434\u043E\u043C\u0443 \u043F\u043B\u0430\u043D\u0443.","\u041C\u0435\u0434\u0438\u0430-\u0433\u0430\u043B\u0435\u0440\u0435\u044F":"\u041E\u043A\u043D\u0430 \u0441 \u0438\u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u044F\u043C\u0438, \u043F\u043E\u0434\u043F\u0438\u0441\u0438 \u0444\u0430\u0439\u043B\u043E\u0432 \u0438 \u0441\u0432\u044F\u0437\u0430\u043D\u043D\u044B\u0435 \u0438\u043A\u043E\u043D\u043A\u0438.","\u041A\u0430\u0440\u0442\u043E\u0447\u043A\u0438 \u0441\u043A\u0440\u0438\u043D\u0448\u043E\u0442\u043E\u0432":"\u0421\u043A\u0440\u0438\u043D\u0448\u043E\u0442\u044B \u0432 \u0432\u0438\u0434\u0435 \u043E\u043A\u043E\u043D \u0438 \u0444\u0430\u0439\u043B\u043E\u0432: \u043A\u0430\u0436\u0434\u044B\u0439 \u044D\u043B\u0435\u043C\u0435\u043D\u0442 \u043C\u043E\u0436\u043D\u043E \u0441\u043A\u0440\u044B\u0442\u044C, \u043F\u0435\u0440\u0435\u0441\u0442\u0430\u0432\u0438\u0442\u044C, \u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0438\u043B\u0438 \u0443\u0434\u0430\u043B\u0438\u0442\u044C.","TXT-\u0444\u0430\u0439\u043B\u044B":"\u0421\u043F\u0438\u0441\u043E\u043A \u0444\u0430\u0439\u043B\u043E\u0432 \u043B\u0438\u0441\u0442\u0430 \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u044F: \u043D\u0430\u0437\u0432\u0430\u043D\u0438\u0435 \u043E\u043A\u043D\u0430, \u043F\u043E\u0434\u043F\u0438\u0441\u044C \u0438 \u0442\u0435\u043A\u0441\u0442 \u0432\u043D\u0443\u0442\u0440\u0438 \u0444\u0430\u0439\u043B\u0430.",\u0424\u0443\u0442\u0435\u0440:"\u0411\u0440\u0435\u043D\u0434\u043E\u0432\u044B\u0439 \u0431\u043B\u043E\u043A, \u043A\u043E\u043F\u0438\u0440\u0430\u0439\u0442 \u0438 \u0431\u0430\u0437\u043E\u0432\u044B\u0435 \u0430\u0441\u0441\u0435\u0442\u044B \u0444\u0443\u0442\u0435\u0440\u0430.","\u041D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044F \u0444\u0443\u0442\u0435\u0440\u0430":"\u0421\u0441\u044B\u043B\u043A\u0438 \u043D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043E\u043D\u043D\u043E\u0439 \u043A\u043E\u043B\u043E\u043D\u043A\u0438 \u0444\u0443\u0442\u0435\u0440\u0430. \u041A\u0430\u0436\u0434\u044B\u0439 \u043F\u0443\u043D\u043A\u0442 \u043C\u043E\u0436\u043D\u043E \u0441\u043A\u0440\u044B\u0442\u044C, \u043F\u0435\u0440\u0435\u0441\u0442\u0430\u0432\u0438\u0442\u044C, \u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0438\u043B\u0438 \u0443\u0434\u0430\u043B\u0438\u0442\u044C.","\u041A\u043E\u043D\u0442\u0430\u043A\u0442\u043D\u044B\u0435 \u0441\u0441\u044B\u043B\u043A\u0438":"\u0421\u0441\u044B\u043B\u043A\u0438 \u043A\u043E\u043D\u0442\u0430\u043A\u0442\u043D\u043E\u0439 \u043A\u043E\u043B\u043E\u043D\u043A\u0438 \u0444\u0443\u0442\u0435\u0440\u0430. \u041A\u0430\u0436\u0434\u044B\u0439 \u043F\u0443\u043D\u043A\u0442 \u043C\u043E\u0436\u043D\u043E \u0441\u043A\u0440\u044B\u0442\u044C, \u043F\u0435\u0440\u0435\u0441\u0442\u0430\u0432\u0438\u0442\u044C, \u0434\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0438\u043B\u0438 \u0443\u0434\u0430\u043B\u0438\u0442\u044C.",\u041F\u043E\u043B\u0438\u0442\u0438\u043A\u0438:"\u041D\u0438\u0436\u043D\u044F\u044F \u0441\u0442\u0440\u043E\u043A\u0430 \u043F\u043E\u043B\u0438\u0442\u0438\u043A \u0438 \u0443\u0441\u043B\u043E\u0432\u0438\u044F \u043E\u0442\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u044F.",\u041A\u043E\u043D\u0442\u0435\u043D\u0442:"\u041E\u0441\u0442\u0430\u043B\u044C\u043D\u044B\u0435 typed-\u043F\u043E\u043B\u044F \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0433\u043E \u0431\u043B\u043E\u043A\u0430."},nL="image/*,video/*,.gif,.webm,.mov,.mp4,.m4v,.avi,.mkv,.glb,.gltf,.svg,.ico,.avif,.webp,.webmanifest,.json,.woff,.woff2",Hm="application/x-nodedc-media-entry",Hw=[["all","\u0412\u0441\u0435"],["image","\u0418\u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u0438\u044F"],["video","\u0412\u0438\u0434\u0435\u043E"],["model","3D"]],lL=[["","\u041F\u0440\u043E\u0435\u043A\u0442"],["assets","Assets"],["assets/uploads","Uploads"],["assets/media","Media"],["assets/site/images","NODE.DC"],["assets/custom","Custom"]],oL='',hn=Pw(),Uv=new WeakMap,Hv=0;o4=new Set(["_blank","_self","_parent","_top"]);for(let e of[c.id,c.label,c.anchor,c.enabled])e.addEventListener("input",Tm),e.addEventListener("change",Tm);c.modeContent?.addEventListener("click",()=>Gm("content"));c.modeSeo?.addEventListener("click",()=>Gm("seo"));c.modeKnowledge?.addEventListener("click",()=>Gm("knowledge"));c.addProject?.addEventListener("click",()=>Nw().catch(e=>D(e.message)));c.projectSettings?.addEventListener("click",H2);c.json.addEventListener("blur",()=>{if(s.mode!=="knowledge"){if(s.filePickerActive||s.mediaUploadActive){Ht();return}y2()}});c.addBlock?.addEventListener("click",()=>{if(s.mode==="knowledge"){rp(null);return}w4()});c.templateModalClose.addEventListener("click",Ui);c.templateModalCancel.addEventListener("click",Ui);c.templateModal.addEventListener("click",e=>{e.target===c.templateModal&&Ui()});c.deleteModalCancel.addEventListener("click",()=>to(!1));c.deleteModalConfirm.addEventListener("click",()=>to(!0));c.deleteModal.addEventListener("click",e=>{e.target===c.deleteModal&&to(!1)});c.mediaActionCancel.addEventListener("click",()=>ao(null));c.mediaActionConfirm.addEventListener("click",()=>ao(c.mediaActionInput.value.trim()));c.mediaActionModal.addEventListener("click",e=>{e.target===c.mediaActionModal&&ao(null)});c.knowledgeButtonClose.addEventListener("click",()=>io(null));c.knowledgeButtonCancel.addEventListener("click",()=>io(null));c.knowledgeButtonConfirm.addEventListener("click",_m);c.knowledgeButtonLink.addEventListener("blur",()=>{c.knowledgeButtonLink.value=Yd(c.knowledgeButtonLink.value)});c.knowledgeButtonModal.addEventListener("click",e=>{e.target===c.knowledgeButtonModal&&io(null)});c.mediaModalClose.addEventListener("click",Pi);c.mediaModalCancel.addEventListener("click",Pi);c.mediaModal.addEventListener("click",e=>{e.target===c.mediaModal&&Pi()});c.mediaSearch.addEventListener("input",()=>{s.mediaLibrary.query=c.mediaSearch.value,lt()});c.mediaRefresh.addEventListener("click",()=>J4().catch(e=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043C\u0435\u0434\u0438\u0430\u0442\u0435\u043A\u0438: ${e.message}`)));c.mediaUpload.addEventListener("click",()=>{if(s.mediaLibrary.trashMode){t2().catch(e=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043E\u0447\u0438\u0441\u0442\u043A\u0438 \u043A\u043E\u0440\u0437\u0438\u043D\u044B: ${e.message}`));return}r2()});c.mediaSelect.addEventListener("click",FL);c.mediaDelete.addEventListener("click",()=>np().catch(e=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u044F: ${e.message}`)));c.mediaTrashToggle.addEventListener("click",()=>e2().catch(e=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043A\u043E\u0440\u0437\u0438\u043D\u044B: ${e.message}`)));c.mediaDropZone.addEventListener("dragover",e=>{s.mediaLibrary.context&&(jd(e)||(e.preventDefault(),c.mediaDropZone.dataset.dragActive="true"))});c.mediaDropZone.addEventListener("dragleave",e=>{c.mediaDropZone.contains(e.relatedTarget)||delete c.mediaDropZone.dataset.dragActive});c.mediaDropZone.addEventListener("drop",e=>{if(!s.mediaLibrary.context||jd(e))return;e.preventDefault(),delete c.mediaDropZone.dataset.dragActive;let t=e.dataTransfer?.files?.[0];o2(t).catch(a=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0437\u0430\u0433\u0440\u0443\u0437\u043A\u0438: ${a.message}`))});document.addEventListener("click",e=>{c.mediaContextMenu.classList.contains("hidden")||c.mediaContextMenu.contains(e.target)||ro()});document.addEventListener("contextmenu",e=>{c.mediaModal.classList.contains("hidden")||c.mediaModal.contains(e.target)||ro()});document.addEventListener("selectionchange",()=>{s.mode==="knowledge"&&Xn()});document.addEventListener("keydown",e=>{if(!c.deleteModal.classList.contains("hidden")){e.key==="Enter"&&(e.preventDefault(),to(!0)),e.key==="Escape"&&(e.preventDefault(),to(!1));return}if(!c.mediaActionModal.classList.contains("hidden")){e.key==="Enter"&&(e.preventDefault(),ao(c.mediaActionInput.value.trim())),e.key==="Escape"&&(e.preventDefault(),ao(null));return}if(!c.knowledgeButtonModal.classList.contains("hidden")){e.key==="Enter"&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),_m()),e.key==="Enter"&&e.target!==c.knowledgeButtonTarget&&(e.preventDefault(),_m()),e.key==="Escape"&&(e.preventDefault(),io(null));return}if(!c.mediaModal.classList.contains("hidden")){if(!c.mediaContextMenu.classList.contains("hidden")&&e.key==="Escape"){e.preventDefault(),ro();return}if(Q4(e.target))return;if(e.key==="ArrowDown"){e.preventDefault(),Xv(1).catch(t=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438: ${t.message}`));return}if(e.key==="ArrowUp"){e.preventDefault(),Xv(-1).catch(t=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438: ${t.message}`));return}if(e.key==="ArrowRight"){e.preventDefault(),$4().catch(t=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438: ${t.message}`));return}if(e.key==="ArrowLeft"){e.preventDefault(),Z4().catch(t=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u043D\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438: ${t.message}`));return}if(e.key==="Delete"||e.key==="Backspace"){(s.mediaLibrary.trashMode?qi()?.trashPath:qd(s.mediaLibrary.selectedEntry))&&(e.preventDefault(),np().catch(t=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u044F: ${t.message}`)));return}e.key==="Escape"&&(e.preventDefault(),Pi());return}e.key==="Escape"&&!c.templateModal.classList.contains("hidden")&&Ui()});c.reload.addEventListener("click",()=>{if(Nt()){Oi().then(Zn).then(()=>D("\u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u043F\u0440\u043E\u0435\u043A\u0442\u0430 \u043F\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043D\u044B.")).catch(t=>D(t.message));return}(s.mode==="knowledge"?dp:rb)().catch(t=>D(t.message))});c.save.addEventListener("click",()=>{if(Nt()){Vw().catch(t=>D(t.message));return}(s.mode==="knowledge"?N2:B2)().catch(t=>D(t.message))});c.render.addEventListener("click",()=>{if(Nt()){Xw().catch(t=>D(t.message));return}(s.mode==="knowledge"?R2:_2)().catch(t=>D(t.message))});c.publish?.addEventListener("click",()=>{Nt()&&Kw().catch(e=>D(e.message))});c.moveUp.addEventListener("click",()=>ub(-1));c.moveDown.addEventListener("click",()=>ub(1));c.duplicate.addEventListener("click",O2);c.copy.addEventListener("click",z2);c.pasteAfter.addEventListener("click",q2);c.deleteBlock.addEventListener("click",()=>U2().catch(e=>D(`\u041E\u0448\u0438\u0431\u043A\u0430 \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u044F: ${e.message}`)));window.addEventListener("error",e=>{Ht(),D(`\u041E\u0448\u0438\u0431\u043A\u0430 JS: ${e.message}`)});window.addEventListener("unhandledrejection",e=>{Ht();let t=e.reason instanceof Error?e.reason.message:String(e.reason);D(`\u041E\u0448\u0438\u0431\u043A\u0430 JS: ${t}`)});rb().catch(e=>D(e.message))});var _v=k(z(),1),Ov=k(Jx(),1),fn=k(Gt(),1);var ny=k(O(),1);var ly=k(O(),1);function _(...e){return e.filter(Boolean).join(" ")}function bd({size:e="default",label:t,className:a,...n}){let l=t?.trim()||void 0;return(0,ly.jsx)("span",{...n,className:_("nodedc-activity-indicator",a),"data-size":e==="default"?void 0:e,role:l?"status":void 0,"aria-label":l,"aria-hidden":l?void 0:"true"})}var ry=k(O(),1),fr=k(z(),1);var oy=k(z(),1),_f=(0,oy.createContext)(null);var sC=k(O(),1);var iy=k(O(),1);var Ay=k(O(),1);var wy=k(O(),1),Kl=k(z(),1),BC=k(Gt(),1);var gt=k(z()),Ly=k(Gt());var mr=k(z());var uy=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Sd(e){let t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function Of(e){return"nodeType"in e}function ht(e){var t,a;return e?Sd(e)?e:Of(e)&&(t=(a=e.ownerDocument)==null?void 0:a.defaultView)!=null?t:window:window}function zf(e){let{Document:t}=ht(e);return e instanceof t}function qf(e){return Sd(e)?!1:e instanceof ht(e).HTMLElement}function Uf(e){return e instanceof ht(e).SVGElement}function Gl(e){return e?Sd(e)?e.document:Of(e)?zf(e)?e:qf(e)||Uf(e)?e.ownerDocument:document:document:document}function dy(e){return function(t){for(var a=arguments.length,n=new Array(a>1?a-1:0),l=1;l{let i=Object.entries(r);for(let[u,d]of i){let m=o[u];m!=null&&(o[u]=m+e*d)}return o},{...t})}}var sy=dy(1),pr=dy(-1);function cC(e){return"clientX"in e&&"clientY"in e}function Hf(e){if(!e)return!1;let{KeyboardEvent:t}=ht(e.target);return t&&e instanceof t}function fC(e){if(!e)return!1;let{TouchEvent:t}=ht(e.target);return t&&e instanceof t}function Pf(e){if(fC(e)){if(e.touches&&e.touches.length){let{clientX:t,clientY:a}=e.touches[0];return{x:t,y:a}}else if(e.changedTouches&&e.changedTouches.length){let{clientX:t,clientY:a}=e.changedTouches[0];return{x:t,y:a}}}return cC(e)?{x:e.clientX,y:e.clientY}:null}var Ff=k(z());var cy;(function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable"})(cy||(cy={}));var hr=Object.freeze({x:0,y:0});function hC(e){if(e.startsWith("matrix3d(")){let t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}else if(e.startsWith("matrix(")){let t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}function gC(e,t,a){let n=hC(t);if(!n)return e;let{scaleX:l,scaleY:o,x:r,y:i}=n,u=e.left-r-(1-l)*parseFloat(a),d=e.top-i-(1-o)*parseFloat(a.slice(a.indexOf(" ")+1)),m=l?e.width/l:e.width,f=o?e.height/o:e.height;return{width:m,height:f,top:d,right:u+m,bottom:d+f,left:u}}var xC={ignoreTransform:!1};function Cd(e,t){t===void 0&&(t=xC);let a=e.getBoundingClientRect();if(t.ignoreTransform){let{transform:d,transformOrigin:m}=ht(e).getComputedStyle(e);d&&(a=gC(a,d,m))}let{top:n,left:l,width:o,height:r,bottom:i,right:u}=a;return{top:n,left:l,width:o,height:r,bottom:i,right:u}}function fy(e){return Cd(e,{ignoreTransform:!0})}function yC(e,t){return t===void 0&&(t=ht(e).getComputedStyle(e)),t.position==="fixed"}function vC(e,t){t===void 0&&(t=ht(e).getComputedStyle(e));let a=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some(l=>{let o=t[l];return typeof o=="string"?a.test(o):!1})}function by(e,t){let a=[];function n(l){if(t!=null&&a.length>=t||!l)return a;if(zf(l)&&l.scrollingElement!=null&&!a.includes(l.scrollingElement))return a.push(l.scrollingElement),a;if(!qf(l)||Uf(l)||a.includes(l))return a;let o=ht(e).getComputedStyle(l);return l!==e&&vC(l,o)&&a.push(l),yC(l,o)?a:n(l.parentNode)}return e?n(e):a}function LC(e){let[t]=by(e,1);return t??null}var Vl;(function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"})(Vl||(Vl={}));function bC(e){return!uy||!e?!1:e===document.scrollingElement}function SC(e){let t={x:0,y:0},a=bC(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},n={x:e.scrollWidth-a.width,y:e.scrollHeight-a.height},l=e.scrollTop<=t.y,o=e.scrollLeft<=t.x,r=e.scrollTop>=n.y,i=e.scrollLeft>=n.x;return{isTop:l,isLeft:o,isBottom:r,isRight:i,maxScroll:n,minScroll:t}}function CC(e){if(e===document.scrollingElement){let{innerWidth:o,innerHeight:r}=window;return{top:0,left:0,right:o,bottom:r,width:o,height:r}}let{top:t,left:a,right:n,bottom:l}=e.getBoundingClientRect();return{top:t,left:a,right:n,bottom:l,width:e.clientWidth,height:e.clientHeight}}function wC(e,t){if(t===void 0&&(t=Cd),!e)return;let{top:a,left:n,bottom:l,right:o}=t(e);LC(e)&&(l<=0||o<=0||a>=window.innerHeight||n>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}var qn=class{constructor(t){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(a=>{var n;return(n=this.target)==null?void 0:n.removeEventListener(...a)})},this.target=t}add(t,a,n){var l;(l=this.target)==null||l.addEventListener(t,a,n),this.listeners.push([t,a,n])}};function IC(e){let{EventTarget:t}=ht(e);return e instanceof t?e:Gl(e)}function jf(e,t){let a=Math.abs(e.x),n=Math.abs(e.y);return typeof t=="number"?Math.sqrt(a**2+n**2)>t:"x"in t&&"y"in t?a>t.x&&n>t.y:"x"in t?a>t.x:"y"in t?n>t.y:!1}var Tt;(function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange"})(Tt||(Tt={}));function my(e){e.preventDefault()}function kC(e){e.stopPropagation()}var K;(function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter",e.Tab="Tab"})(K||(K={}));var Sy={start:[K.Space,K.Enter],cancel:[K.Esc],end:[K.Space,K.Enter,K.Tab]},EC=(e,t)=>{let{currentCoordinates:a}=t;switch(e.code){case K.Right:return{...a,x:a.x+25};case K.Left:return{...a,x:a.x-25};case K.Down:return{...a,y:a.y+25};case K.Up:return{...a,y:a.y-25}}},Vf=class{constructor(t){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=t;let{event:{target:a}}=t;this.props=t,this.listeners=new qn(Gl(a)),this.windowListeners=new qn(ht(a)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(Tt.Resize,this.handleCancel),this.windowListeners.add(Tt.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(Tt.Keydown,this.handleKeyDown))}handleStart(){let{activeNode:t,onStart:a}=this.props,n=t.node.current;n&&wC(n),a(hr)}handleKeyDown(t){if(Hf(t)){let{active:a,context:n,options:l}=this.props,{keyboardCodes:o=Sy,coordinateGetter:r=EC,scrollBehavior:i="smooth"}=l,{code:u}=t;if(o.end.includes(u)){this.handleEnd(t);return}if(o.cancel.includes(u)){this.handleCancel(t);return}let{collisionRect:d}=n.current,m=d?{x:d.left,y:d.top}:hr;this.referenceCoordinates||(this.referenceCoordinates=m);let f=r(t,{active:a,context:n.current,currentCoordinates:m});if(f){let g=pr(f,m),h={x:0,y:0},{scrollableAncestors:v}=n.current;for(let S of v){let C=t.code,{isTop:x,isRight:p,isLeft:y,isBottom:L,maxScroll:M,minScroll:E}=SC(S),I=CC(S),N={x:Math.min(C===K.Right?I.right-I.width/2:I.right,Math.max(C===K.Right?I.left:I.left+I.width/2,f.x)),y:Math.min(C===K.Down?I.bottom-I.height/2:I.bottom,Math.max(C===K.Down?I.top:I.top+I.height/2,f.y))},A=C===K.Right&&!p||C===K.Left&&!y,T=C===K.Down&&!L||C===K.Up&&!x;if(A&&N.x!==f.x){let B=S.scrollLeft+g.x,le=C===K.Right&&B<=M.x||C===K.Left&&B>=E.x;if(le&&!g.y){S.scrollTo({left:B,behavior:i});return}le?h.x=S.scrollLeft-B:h.x=C===K.Right?S.scrollLeft-M.x:S.scrollLeft-E.x,h.x&&S.scrollBy({left:-h.x,behavior:i});break}else if(T&&N.y!==f.y){let B=S.scrollTop+g.y,le=C===K.Down&&B<=M.y||C===K.Up&&B>=E.y;if(le&&!g.x){S.scrollTo({top:B,behavior:i});return}le?h.y=S.scrollTop-B:h.y=C===K.Down?S.scrollTop-M.y:S.scrollTop-E.y,h.y&&S.scrollBy({top:-h.y,behavior:i});break}}this.handleMove(t,sy(pr(f,this.referenceCoordinates),h))}}}handleMove(t,a){let{onMove:n}=this.props;t.preventDefault(),n(a)}handleEnd(t){let{onEnd:a}=this.props;t.preventDefault(),this.detach(),a()}handleCancel(t){let{onCancel:a}=this.props;t.preventDefault(),this.detach(),a()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}};Vf.activators=[{eventName:"onKeyDown",handler:(e,t,a)=>{let{keyboardCodes:n=Sy,onActivation:l}=t,{active:o}=a,{code:r}=e.nativeEvent;if(n.start.includes(r)){let i=o.activatorNode.current;return i&&e.target!==i?!1:(e.preventDefault(),l?.({event:e.nativeEvent}),!0)}return!1}}];function py(e){return!!(e&&"distance"in e)}function hy(e){return!!(e&&"delay"in e)}var gr=class{constructor(t,a,n){var l;n===void 0&&(n=IC(t.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=t,this.events=a;let{event:o}=t,{target:r}=o;this.props=t,this.events=a,this.document=Gl(r),this.documentListeners=new qn(this.document),this.listeners=new qn(n),this.windowListeners=new qn(ht(r)),this.initialCoordinates=(l=Pf(o))!=null?l:hr,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){let{events:t,props:{options:{activationConstraint:a,bypassActivationConstraint:n}}}=this;if(this.listeners.add(t.move.name,this.handleMove,{passive:!1}),this.listeners.add(t.end.name,this.handleEnd),t.cancel&&this.listeners.add(t.cancel.name,this.handleCancel),this.windowListeners.add(Tt.Resize,this.handleCancel),this.windowListeners.add(Tt.DragStart,my),this.windowListeners.add(Tt.VisibilityChange,this.handleCancel),this.windowListeners.add(Tt.ContextMenu,my),this.documentListeners.add(Tt.Keydown,this.handleKeydown),a){if(n!=null&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(hy(a)){this.timeoutId=setTimeout(this.handleStart,a.delay),this.handlePending(a);return}if(py(a)){this.handlePending(a);return}}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),this.timeoutId!==null&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handlePending(t,a){let{active:n,onPending:l}=this.props;l(n,t,this.initialCoordinates,a)}handleStart(){let{initialCoordinates:t}=this,{onStart:a}=this.props;t&&(this.activated=!0,this.documentListeners.add(Tt.Click,kC,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(Tt.SelectionChange,this.removeTextSelection),a(t))}handleMove(t){var a;let{activated:n,initialCoordinates:l,props:o}=this,{onMove:r,options:{activationConstraint:i}}=o;if(!l)return;let u=(a=Pf(t))!=null?a:hr,d=pr(l,u);if(!n&&i){if(py(i)){if(i.tolerance!=null&&jf(d,i.tolerance))return this.handleCancel();if(jf(d,i.distance))return this.handleStart()}if(hy(i)&&jf(d,i.tolerance))return this.handleCancel();this.handlePending(i,d);return}t.cancelable&&t.preventDefault(),r(u)}handleEnd(){let{onAbort:t,onEnd:a}=this.props;this.detach(),this.activated||t(this.props.active),a()}handleCancel(){let{onAbort:t,onCancel:a}=this.props;this.detach(),this.activated||t(this.props.active),a()}handleKeydown(t){t.code===K.Esc&&this.handleCancel()}removeTextSelection(){var t;(t=this.document.getSelection())==null||t.removeAllRanges()}},MC={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}},xr=class extends gr{constructor(t){let{event:a}=t,n=Gl(a.target);super(t,MC,n)}};xr.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:a}=e,{onActivation:n}=t;return!a.isPrimary||a.button!==0?!1:(n?.({event:a}),!0)}}];var AC={move:{name:"mousemove"},end:{name:"mouseup"}},Xf;(function(e){e[e.RightClick=2]="RightClick"})(Xf||(Xf={}));var Kf=class extends gr{constructor(t){super(t,AC,Gl(t.event.target))}};Kf.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:a}=e,{onActivation:n}=t;return a.button===Xf.RightClick?!1:(n?.({event:a}),!0)}}];var Gf={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}},Yf=class extends gr{constructor(t){super(t,Gf)}static setup(){return window.addEventListener(Gf.move.name,t,{capture:!1,passive:!1}),function(){window.removeEventListener(Gf.move.name,t)};function t(){}}};Yf.activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:a}=e,{onActivation:n}=t,{touches:l}=a;return l.length>1?!1:(n?.({event:a}),!0)}}];var gy;(function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect"})(gy||(gy={}));var xy;(function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder"})(xy||(xy={}));var II={x:{[Vl.Backward]:!1,[Vl.Forward]:!1},y:{[Vl.Backward]:!1,[Vl.Forward]:!1}};var $f;(function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging"})($f||($f={}));var Zf;(function(e){e.Optimized="optimized"})(Zf||(Zf={}));var kI={draggable:{measure:fy},droppable:{measure:fy,strategy:$f.WhileDragging,frequency:Zf.Optimized},dragOverlay:{measure:Cd}};var EI=(0,gt.createContext)({...hr,scaleX:1,scaleY:1}),yy;(function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized"})(yy||(yy={}));var Xl=k(z());var _I=[K.Down,K.Right,K.Up,K.Left];var KI=(0,Kl.createContext)(!1);var My=k(O(),1);var Id=k(z());/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Iy=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),wd=(...e)=>e.filter((t,a,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===a).join(" ").trim();var yr=k(z());/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ky={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"};/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Ey=(0,yr.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:n,className:l="",children:o,iconNode:r,...i},u)=>(0,yr.createElement)("svg",{ref:u,...ky,width:t,height:t,stroke:e,strokeWidth:n?Number(a)*24/Number(t):a,className:wd("lucide",l),...i},[...r.map(([d,m])=>(0,yr.createElement)(d,m)),...Array.isArray(o)?o:[o]]));/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var b=(e,t)=>{let a=(0,Id.forwardRef)(({className:n,...l},o)=>(0,Id.createElement)(Ey,{ref:o,iconNode:t,className:wd(`lucide-${Iy(e)}`,n),...l}));return a.displayName=`${e}`,a};/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var vr=b("Activity",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Lr=b("Box",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var br=b("Boxes",[["path",{d:"M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z",key:"lc1i9w"}],["path",{d:"m7 16.5-4.74-2.85",key:"1o9zyk"}],["path",{d:"m7 16.5 5-3",key:"va8pkn"}],["path",{d:"M7 16.5v5.17",key:"jnp8gn"}],["path",{d:"M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z",key:"8zsnat"}],["path",{d:"m17 16.5-5-3",key:"8arw3v"}],["path",{d:"m17 16.5 4.74-2.85",key:"8rfmw"}],["path",{d:"M17 16.5v5.17",key:"k6z78m"}],["path",{d:"M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z",key:"1xygjf"}],["path",{d:"M12 8 7.26 5.15",key:"1vbdud"}],["path",{d:"m12 8 4.74-2.85",key:"3rx089"}],["path",{d:"M12 13.5V8",key:"1io7kd"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Sr=b("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Cr=b("Camera",[["path",{d:"M14.5 4h-5L7 7H4a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-3l-2.5-3z",key:"1tc9qg"}],["circle",{cx:"12",cy:"13",r:"3",key:"1vg3eu"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var wr=b("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Ir=b("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var kr=b("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Er=b("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Mr=b("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var en=b("CirclePlus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var tn=b("CircleUser",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}],["path",{d:"M7 20.662V19a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v1.662",key:"154egf"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Ar=b("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Dr=b("ClipboardList",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var an=b("CloudUpload",[["path",{d:"M12 13v8",key:"1l5pq0"}],["path",{d:"M4 14.899A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.5 8.242",key:"1pljnt"}],["path",{d:"m8 17 4-4 4 4",key:"1quai1"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Tr=b("Copy",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Nr=b("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Rr=b("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var nn=b("Earth",[["path",{d:"M21.54 15H17a2 2 0 0 0-2 2v4.54",key:"1djwo0"}],["path",{d:"M7 3.34V5a3 3 0 0 0 3 3a2 2 0 0 1 2 2c0 1.1.9 2 2 2a2 2 0 0 0 2-2c0-1.1.9-2 2-2h3.17",key:"1tzkfa"}],["path",{d:"M11 21.95V18a2 2 0 0 0-2-2a2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05",key:"14pb5j"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Br=b("ExternalLink",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var _r=b("EyeOff",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Or=b("Eye",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var zr=b("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var qr=b("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Ur=b("Image",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Hr=b("Inbox",[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Pr=b("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Fr=b("KeyRound",[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ln=b("Layers",[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var jr=b("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Gr=b("ListChecks",[["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}],["path",{d:"M13 6h8",key:"15sg57"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 18h8",key:"oe0vm4"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Vr=b("LocateFixed",[["line",{x1:"2",x2:"5",y1:"12",y2:"12",key:"bvdh0s"}],["line",{x1:"19",x2:"22",y1:"12",y2:"12",key:"1tbv5k"}],["line",{x1:"12",x2:"12",y1:"2",y2:"5",key:"11lu5j"}],["line",{x1:"12",x2:"12",y1:"19",y2:"22",key:"x3vr5v"}],["circle",{cx:"12",cy:"12",r:"7",key:"fim9np"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Xr=b("LockKeyhole",[["circle",{cx:"12",cy:"16",r:"1",key:"1au0dj"}],["rect",{x:"3",y:"10",width:"18",height:"12",rx:"2",key:"6s8ecr"}],["path",{d:"M7 10V7a5 5 0 0 1 10 0v3",key:"1pqi11"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Kr=b("MailPlus",[["path",{d:"M22 13V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h8",key:"12jkf8"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}],["path",{d:"M19 16v6",key:"tddt3s"}],["path",{d:"M16 19h6",key:"xwg31i"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Yr=b("Map",[["path",{d:"M14.106 5.553a2 2 0 0 0 1.788 0l3.659-1.83A1 1 0 0 1 21 4.619v12.764a1 1 0 0 1-.553.894l-4.553 2.277a2 2 0 0 1-1.788 0l-4.212-2.106a2 2 0 0 0-1.788 0l-3.659 1.83A1 1 0 0 1 3 19.381V6.618a1 1 0 0 1 .553-.894l4.553-2.277a2 2 0 0 1 1.788 0z",key:"169xi5"}],["path",{d:"M15 5.764v15",key:"1pn4in"}],["path",{d:"M9 3.236v15",key:"1uimfh"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var $r=b("Maximize2",[["polyline",{points:"15 3 21 3 21 9",key:"mznyad"}],["polyline",{points:"9 21 3 21 3 15",key:"1avn1i"}],["line",{x1:"21",x2:"14",y1:"3",y2:"10",key:"ota7mn"}],["line",{x1:"3",x2:"10",y1:"21",y2:"14",key:"1atl0r"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Zr=b("Minimize2",[["polyline",{points:"4 14 10 14 10 20",key:"11kfnr"}],["polyline",{points:"20 10 14 10 14 4",key:"rlmsce"}],["line",{x1:"14",x2:"21",y1:"10",y2:"3",key:"o5lafz"}],["line",{x1:"3",x2:"10",y1:"21",y2:"14",key:"1atl0r"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Qr=b("Minus",[["path",{d:"M5 12h14",key:"1ays0h"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Wr=b("MousePointer2",[["path",{d:"M4.037 4.688a.495.495 0 0 1 .651-.651l16 6.5a.5.5 0 0 1-.063.947l-6.124 1.58a2 2 0 0 0-1.438 1.435l-1.579 6.126a.5.5 0 0 1-.947.063z",key:"edeuup"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Jr=b("Move",[["path",{d:"M12 2v20",key:"t6zp3m"}],["path",{d:"m15 19-3 3-3-3",key:"11eu04"}],["path",{d:"m19 9 3 3-3 3",key:"1mg7y2"}],["path",{d:"M2 12h20",key:"9i4pu4"}],["path",{d:"m5 9-3 3 3 3",key:"j64kie"}],["path",{d:"m9 5 3-3 3 3",key:"l8vdw6"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ei=b("Network",[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ti=b("PanelTop",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ai=b("PenTool",[["path",{d:"M15.707 21.293a1 1 0 0 1-1.414 0l-1.586-1.586a1 1 0 0 1 0-1.414l5.586-5.586a1 1 0 0 1 1.414 0l1.586 1.586a1 1 0 0 1 0 1.414z",key:"nt11vn"}],["path",{d:"m18 13-1.375-6.874a1 1 0 0 0-.746-.776L3.235 2.028a1 1 0 0 0-1.207 1.207L5.35 15.879a1 1 0 0 0 .776.746L13 18",key:"15qc1e"}],["path",{d:"m2.3 2.3 7.286 7.286",key:"1wuzzi"}],["circle",{cx:"11",cy:"11",r:"2",key:"xmgehs"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ni=b("Pencil",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var li=b("Play",[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var oi=b("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ri=b("Power",[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ii=b("RectangleHorizontal",[["rect",{width:"20",height:"12",x:"2",y:"6",rx:"2",key:"9lu3g6"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ui=b("Redo2",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var di=b("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var si=b("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var ci=b("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var fi=b("Scan",[["path",{d:"M3 7V5a2 2 0 0 1 2-2h2",key:"aa7l1z"}],["path",{d:"M17 3h2a2 2 0 0 1 2 2v2",key:"4qcy5o"}],["path",{d:"M21 17v2a2 2 0 0 1-2 2h-2",key:"6vwrx8"}],["path",{d:"M7 21H5a2 2 0 0 1-2-2v-2",key:"ioqczr"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var mi=b("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var pi=b("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var hi=b("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var gi=b("SlidersHorizontal",[["line",{x1:"21",x2:"14",y1:"4",y2:"4",key:"obuewd"}],["line",{x1:"10",x2:"3",y1:"4",y2:"4",key:"1q6298"}],["line",{x1:"21",x2:"12",y1:"12",y2:"12",key:"1iu8h1"}],["line",{x1:"8",x2:"3",y1:"12",y2:"12",key:"ntss68"}],["line",{x1:"21",x2:"16",y1:"20",y2:"20",key:"14d8ph"}],["line",{x1:"12",x2:"3",y1:"20",y2:"20",key:"m0wm8r"}],["line",{x1:"14",x2:"14",y1:"2",y2:"6",key:"14e1ph"}],["line",{x1:"8",x2:"8",y1:"10",y2:"14",key:"1i6ji0"}],["line",{x1:"16",x2:"16",y1:"18",y2:"22",key:"1lctlv"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var xi=b("Spline",[["circle",{cx:"19",cy:"5",r:"2",key:"mhkx31"}],["circle",{cx:"5",cy:"19",r:"2",key:"v8kfzx"}],["path",{d:"M5 17A12 12 0 0 1 17 5",key:"1okkup"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var yi=b("Square",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var vi=b("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Li=b("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var on=b("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var bi=b("Undo2",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var rn=b("UsersRound",[["path",{d:"M18 21a8 8 0 0 0-16 0",key:"3ypg7q"}],["circle",{cx:"10",cy:"8",r:"5",key:"o932ke"}],["path",{d:"M22 20c0-3.37-2-6.5-4-8a5 5 0 0 0-.45-8.3",key:"10s06x"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Si=b("Video",[["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"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var Ci=b("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/** * @license lucide-react v0.468.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var _C={"add-point":en,perspective:Lr,orthographic:fi,select:Wr,move:Jr,pen:ai,rectangle:ii,curve:xi,undo:bi,redo:ui,activity:vr,alert:on,apps:br,building:Sr,camera:Cr,check:wr,"chevron-down":Ir,"chevron-up":Mr,"chevron-left":kr,"chevron-right":Er,circle:Ar,clipboard:Dr,close:Ci,copy:Tr,database:Nr,download:Rr,edit:ni,eye:Or,"eye-off":_r,expand:$r,external:Br,file:zr,folder:qr,globe:nn,grid:jr,image:Ur,inbox:Hr,info:Pr,key:Fr,layers:ln,list:Gr,target:Vr,lock:Xr,mail:Kr,minimize:Zr,network:ei,panel:ti,plan:Yr,play:li,power:ri,plus:oi,minus:Qr,profile:tn,refresh:di,"rotate-clockwise":si,save:ci,search:mi,settings:pi,shield:hi,sliders:gi,stop:yi,terminal:vi,trash:Li,upload:an,users:rn,video:Si};function ve({name:e,label:t,size:a=16,strokeWidth:n=1.6,fill:l,...o}){let r=_C[e],i=e==="play"||e==="stop";return(0,My.jsx)(r,{size:a,strokeWidth:i?0:n,fill:l??(i?"currentColor":"none"),"aria-hidden":t?void 0:"true","aria-label":t,role:t?"img":void 0,focusable:"false",...o})}var Dy=k(O(),1);var Qf=k(O(),1),Un=k(z(),1),zC=k(Gt(),1),XM=(0,Un.createContext)(null);var Ty=k(O(),1);var Ny=k(z(),1);var Qt=k(O(),1),tm=k(z(),1);function By(e){return Math.max(0,Math.min(255,Math.round(e)))}function qC(e){let t=By(e)/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4}function UC(e){let[t,a,n]=e.map(qC);return t*.2126+a*.7152+n*.0722}function _y(e){return UC(e)>.46?[11,17,23]:[247,248,244]}function Ry(e){return e.map(By).join(" ")}function wi(e){return{"--nodedc-accent-rgb":Ry(e),"--nodedc-on-accent-rgb":Ry(_y(e))}}function Wf({anchor:e,surfaceWidth:t,surfaceHeight:a,placement:n="bottom-start",offset:l=8,flip:o=!0,viewportWidth:r=typeof window>"u"?1920:window.innerWidth,viewportHeight:i=typeof window>"u"?1080:window.innerHeight,viewportPadding:u=8}){let d=Math.max(0,i-u*2);if(n.startsWith("left")||n.startsWith("right")){let E=Math.max(0,e.left-l-u),I=Math.max(0,r-e.right-l-u),N=n.startsWith("left"),T=o&&(N?t>E&&I>E:t>I&&E>I)?!N:N,B=T?E:I,le=Math.min(t,B),Bt=Math.min(a,d);return{left:T?e.left-l-le:e.right+l,top:Math.max(u,Math.min(e.top,i-u-Bt)),maxHeight:d,maxWidth:B,resolvedPlacement:T?"left-start":"right-start"}}let m=Math.min(d,Math.max(0,i-e.bottom-l-u)),f=Math.min(d,Math.max(0,e.top-l-u)),g=n.startsWith("top"),v=o&&(g?a>f&&m>f:a>m&&f>m)?`${g?"bottom":"top"}-${n.endsWith("end")?"end":"start"}`:n,S=v.endsWith("end")?e.right-t:e.left,C=Math.min(Math.max(u,S),Math.max(u,r-t-u)),x=v.startsWith("top")?f:m,p=Math.min(d,Math.max(Math.min(96,d),x)),y=Math.min(a,p),L=v.startsWith("top")?e.top-l-y:e.bottom+l;return{top:Math.min(Math.max(u,L),Math.max(u,i-y-u)),left:C,maxHeight:p,resolvedPlacement:v}}function Oy([e,t,a]){return`${e} ${t} ${a}`}function kd(e){return Math.max(0,Math.min(1,e))}function Jf(e,{theme:t="dark",accent:a,material:n,appearance:l="default"}={}){if(e.dataset.nodedcTheme=t,e.dataset.nodedcAppearance=l,e.dataset.nodedcUi="true",a){let o=wi(a);Object.entries(o).forEach(([r,i])=>{e.style.setProperty(r,i)})}if(n){if(n.panel&&e.style.setProperty("--nodedc-panel-material-rgb",Oy(n.panel)),typeof n.panelOpacity=="number"&&Number.isFinite(n.panelOpacity)){let o=kd(n.panelOpacity);e.style.setProperty("--nodedc-panel-material-opacity",String(o)),e.style.setProperty("--nodedc-panel-material-strong-opacity",String(kd(o+.12))),e.style.setProperty("--nodedc-panel-material-soft-opacity",String(kd(Math.max(.12,o-.2))))}n.field&&e.style.setProperty("--nodedc-field-material-rgb",Oy(n.field)),typeof n.fieldOpacity=="number"&&Number.isFinite(n.fieldOpacity)&&e.style.setProperty("--nodedc-field-material-opacity",String(kd(n.fieldOpacity)))}}var zy=Object.freeze({background:"#111115",border:"#111117",outline:"#1c1c1c",minSize:25,maxSize:87,lensCount:5,gap:10,padding:6,hideDelay:5e3}),uA=Object.freeze({mass:.1,stiffness:170,damping:12,maxStep:1/240});var un=(0,tm.forwardRef)(function({variant:t="secondary",tone:a="theme",size:n="default",width:l="auto",shape:o="default",accent:r,icon:i,className:u,children:d,style:m,type:f="button",loading:g=!1,disabled:h,...v},S){let C=r?wi(r):void 0;return(0,Qt.jsxs)("button",{ref:S,type:f,className:_("nodedc-button",u),"data-variant":t,"data-tone":a==="theme"?void 0:a,"data-size":n==="default"?void 0:n,"data-width":l==="auto"?void 0:l,"data-shape":o==="default"?void 0:o,style:C?{...C,...m}:m,...v,disabled:h||g,"aria-busy":g||v["aria-busy"],"data-loading":g||void 0,children:[(0,Qt.jsxs)("span",{className:"nodedc-button__content",children:[i?(0,Qt.jsx)("span",{className:"nodedc-button__icon","aria-hidden":"true",children:i}):null,d]}),g?(0,Qt.jsx)("span",{className:"nodedc-action-loading","aria-hidden":"true",children:(0,Qt.jsx)(bd,{size:"compact"})}):null]})}),qt=(0,tm.forwardRef)(function({label:t,shape:a="circle",className:n,children:l,type:o="button",loading:r=!1,disabled:i,...u},d){return(0,Qt.jsxs)("button",{ref:d,type:o,className:_("nodedc-icon-button",n),"data-shape":a==="circle"?void 0:a,"aria-label":t,title:t,...u,disabled:i||r,"aria-busy":r||u["aria-busy"],"data-loading":r||void 0,children:[l,r?(0,Qt.jsx)("span",{className:"nodedc-action-loading","aria-hidden":"true",children:(0,Qt.jsx)(bd,{size:"compact"})}):null]})});var nm=k(O(),1),jC=k(z(),1);var am=k(O(),1);function Ii({label:e,value:t,valueText:a,className:n,style:l,...o}){let r=typeof t=="number"&&Number.isFinite(t)?Math.max(0,Math.min(1,t)):void 0;return(0,am.jsx)("div",{...o,className:_("nodedc-progress-bar",n),role:"progressbar","aria-label":e,"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":r===void 0?void 0:Math.round(r*100),"aria-valuetext":a,"data-indeterminate":r===void 0||void 0,style:{...l,"--nodedc-progress-fraction":r??0},children:(0,am.jsx)("span",{className:"nodedc-progress-bar__fill"})})}var Py=k(O(),1);var lm=k(O(),1),om=k(z(),1);var Vy=k(O(),1),Yl=k(z(),1),KC=k(Gt(),1);var Fy=k(z(),1),ki=(0,Fy.createContext)(!1);var jy=k(z(),1),Gy=(0,jy.createContext)(null);var ZA=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])","[tabindex]:not([tabindex='-1'])"].join(",");var Ei=k(O(),1),ne=k(z(),1),$y=k(Gt(),1);var Yy=(0,ne.createContext)([]),rm=new Map;function dn({trigger:e,children:t,placement:a="bottom-start",minWidth:n=180,width:l="anchor",offset:o=8,disabled:r=!1,className:i,surfaceClassName:u,surfaceRole:d="menu",onOpenChange:m,getAnchorRect:f,flip:g=!0,onPointerDownOutside:h}){let v=(0,ne.useId)(),S=(0,ne.useContext)(Yy),C=(0,ne.useMemo)(()=>[...S,v],[S,v]),x=`${v.replaceAll(":","")}-surface`,[p,y]=(0,ne.useState)(!1),[L,M]=(0,ne.useState)(null),[E,I]=(0,ne.useState)(null),N=(0,ne.useRef)(null),[A,T]=(0,ne.useState)({visibility:"hidden"});(0,ne.useEffect)(()=>{m?.(p)},[p,m]);let B=(0,ne.useCallback)(()=>y(!1),[]),le=(0,ne.useCallback)(()=>{r||y(!0)},[r]),Bt=(0,ne.useCallback)(()=>{r||y(ge=>!ge)},[r]),yt=(0,ne.useCallback)(()=>{let ge=L??E;if(!ge||!N.current)return;let X=f?.()??ge.getBoundingClientRect();if(!(X.bottom>0&&X.top0&&X.leftObject.keys(so).every(ji=>Fi[ji]===so[ji])?Fi:so)},[L,B,n,o,a,E,l,f,g]);return(0,ne.useLayoutEffect)(()=>{p&&yt()},[p,yt]),(0,ne.useEffect)(()=>{if(!p||!f)return;let ge,X=()=>{yt(),ge=requestAnimationFrame(X)};return ge=requestAnimationFrame(X),()=>cancelAnimationFrame(ge)},[p,f,yt]),(0,ne.useEffect)(()=>{if(!p)return;let ge=Pe=>{let Re=Pe.target;!(Re instanceof Node)||L?.contains(Re)||E?.contains(Re)||N.current?.contains(Re)||(Re instanceof Element?Re:Re.parentElement)?.closest("[data-dropdown-lineage]")?.getAttribute("data-dropdown-lineage")?.split(" ").includes(v)||(B(),h?.(Pe))},X=Pe=>{if(Pe.key==="Escape"&&!Pe.defaultPrevented){if([...rm].some(([Re,ea])=>Re!==v&&ea.includes(v)))return;B(),Pe.preventDefault(),Pe.stopImmediatePropagation(),E?.focus()}},Jt=Pe=>{let Re=Pe.detail;Re.id!==v&&!Re.lineage?.includes(v)&&B()},vt=()=>yt();return rm.set(v,C),window.dispatchEvent(new CustomEvent("nodedc-dropdown-open",{detail:{id:v,lineage:C}})),document.addEventListener("pointerdown",ge,!0),document.addEventListener("keydown",X,!0),window.addEventListener("nodedc-dropdown-open",Jt),window.addEventListener("resize",vt),window.addEventListener("scroll",vt,!0),()=>{rm.delete(v),document.removeEventListener("pointerdown",ge,!0),document.removeEventListener("keydown",X,!0),window.removeEventListener("nodedc-dropdown-open",Jt),window.removeEventListener("resize",vt),window.removeEventListener("scroll",vt,!0)}},[L,B,v,p,E,yt,C,h]),(0,Ei.jsxs)("span",{className:_("nodedc-dropdown-anchor",i),children:[e({open:p,show:le,close:B,toggle:Bt,setAnchorRef:M,setTriggerRef:I,surfaceId:x}),p&&typeof document<"u"?(0,$y.createPortal)((0,Ei.jsx)("div",{ref:N,id:x,"data-dropdown-lineage":C.join(" "),className:_("nodedc-dropdown-surface",u),role:d,style:A,children:(0,Ei.jsx)(Yy.Provider,{value:C,children:typeof t=="function"?t({close:B}):t})}),document.fullscreenElement??document.body):null]})}var ev=k(O(),1),Hn=k(z(),1);var Zy=k(O(),1),Qy=k(z(),1);var fD=(0,Hn.createContext)({disabled:!0,onKey:()=>{}});var tv=k(O(),1),Ed=k(z(),1);var av=k(O(),1),$l=k(z(),1),ew=k(Gt(),1);var nv=k(O(),1),tw=k(z(),1);var lv=k(O(),1),ov=k(z(),1);var nw=k(O(),1);var rv=k(O(),1),iv=k(z(),1);var V=k(O(),1),sn=k(z(),1);function Mi({value:e,options:t,label:a,onChange:n,searchable:l=!1,searchPlaceholder:o="\u041F\u043E\u0438\u0441\u043A",emptyLabel:r="\u041D\u0438\u0447\u0435\u0433\u043E \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D\u043E",placement:i="bottom-start",minMenuWidth:u=180,menuWidth:d="anchor",disabled:m=!1,variant:f="integrated",className:g,triggerClassName:h,menuClassName:v}){let C=(0,sn.useContext)(ki)?"split":f,[x,p]=(0,sn.useState)(""),y=(0,sn.useRef)(null),L=t.find(N=>N.value===e)??t[0],M=t.some(N=>N.action),E=M?"dialog":"listbox",I=(0,sn.useMemo)(()=>{let N=x.trim().toLocaleLowerCase();return N?t.filter(A=>`${A.label} ${A.description??""}`.toLocaleLowerCase().includes(N)):t},[t,x]);return(0,V.jsx)(dn,{className:_("nodedc-select-anchor",g),placement:i,minWidth:u,width:d,disabled:m,surfaceRole:E,surfaceClassName:_(C==="split"&&"nodedc-select__menu",v),trigger:({open:N,toggle:A,setAnchorRef:T,setTriggerRef:B,surfaceId:le})=>{let Bt=ge=>{y.current=ge.currentTarget,A()},yt=ge=>{y.current=ge.currentTarget,(ge.key==="ArrowDown"||ge.key==="Enter"||ge.key===" ")&&(ge.preventDefault(),N||A())};return C==="split"?(0,V.jsx)("div",{className:_("nodedc-select",h),"data-disabled":m?"true":void 0,children:(0,V.jsxs)("div",{ref:T,className:"nodedc-select__control",children:[(0,V.jsxs)("div",{className:"nodedc-select__value",children:[L?.icon?(0,V.jsx)("span",{className:"nodedc-select__value-icon",children:L.icon}):null,(0,V.jsx)("span",{children:L?.label??"\u2014"})]}),(0,V.jsx)("button",{ref:B,type:"button",className:"nodedc-select__toggle","aria-label":a,"aria-haspopup":E,"aria-controls":le,"aria-expanded":N,disabled:m,onClick:Bt,onKeyDown:yt,children:(0,V.jsx)("span",{className:"nodedc-select-trigger__chevron","aria-hidden":"true"})})]})}):C==="inline"?(0,V.jsxs)("button",{ref:B,type:"button",className:_("nodedc-select-inline",h),"aria-label":a,"aria-haspopup":E,"aria-controls":le,"aria-expanded":N,disabled:m,onClick:Bt,onKeyDown:yt,children:[L?.icon?(0,V.jsx)("span",{className:"nodedc-select-trigger__icon",children:L.icon}):null,(0,V.jsx)("span",{children:L?.label??"\u2014"})]}):(0,V.jsxs)("button",{ref:B,type:"button",className:_("nodedc-select-trigger",h),"aria-label":a,"aria-haspopup":E,"aria-controls":le,"aria-expanded":N,disabled:m,onClick:Bt,onKeyDown:yt,children:[L?.icon?(0,V.jsx)("span",{className:"nodedc-select-trigger__icon",children:L.icon}):(0,V.jsx)("span",{className:"nodedc-select-trigger__icon","aria-hidden":"true"}),(0,V.jsx)("span",{className:"nodedc-select-trigger__label",children:L?.label??"\u2014"}),(0,V.jsx)("span",{className:"nodedc-select-trigger__chevron","aria-hidden":"true"})]})},children:({close:N})=>(0,V.jsxs)(V.Fragment,{children:[l?(0,V.jsxs)("label",{className:"nodedc-dropdown-search",children:[(0,V.jsx)("span",{"aria-hidden":"true",children:"\u2315"}),(0,V.jsx)("input",{value:x,onChange:A=>p(A.target.value),placeholder:o})]}):null,I.map(A=>(0,V.jsxs)("div",{className:"nodedc-select-option-row",children:[(0,V.jsxs)("button",{type:"button",className:"nodedc-dropdown-option",role:M?void 0:"option","aria-selected":M?void 0:A.value===e,"aria-pressed":M?A.value===e:void 0,"data-selected":A.value===e?"true":void 0,disabled:A.disabled,onClick:()=>{A.disabled||(n(A.value,A),p(""),N())},children:[A.icon?(0,V.jsx)("span",{className:"nodedc-dropdown-option__icon",children:A.icon}):(0,V.jsx)("span",{}),(0,V.jsxs)("span",{className:"nodedc-dropdown-option__body",children:[(0,V.jsx)("span",{className:"nodedc-dropdown-option__label",children:A.label}),A.description?(0,V.jsx)("span",{className:"nodedc-dropdown-option__description",children:A.description}):null]}),A.value===e?(0,V.jsx)("span",{className:"nodedc-dropdown-option__check","aria-hidden":"true",children:"\u2022"}):null]}),A.action?(0,V.jsx)(qt,{label:A.action.label,"data-tone":A.action.tone??"neutral",disabled:A.action.disabled,onClick:()=>{p(""),N(),y.current?.focus(),A.action?.onAction()},children:A.action.icon}):null]},A.value)),I.length===0?(0,V.jsx)("div",{className:"nodedc-empty-state",children:r}):null]})})}var uv=k(O(),1),lw=k(z(),1);var dv=k(O(),1),ow=k(z(),1);var Ue=k(O(),1),tt=k(z(),1);var Pn=k(O(),1),fv=k(z(),1),Md=k(z(),1);var Ai=(e,t,a)=>Math.max(t,Math.min(a,e));function im(e,t,a){let n=Ai(e[0],t,a);return[n,Ai(e[1],n,a)]}function sv([e,t],a){return a<=(e+t)/2?0:1}function cv(e,t,a,n,l,o=1){let r=im(e,n,l),i=Number(o),u=Ai(a,n,l),d=u===n||u===l||!Number.isFinite(i)||i<=0?u:Number((n+Math.round((u-n)/i)*i).toPrecision(12));return r[t]=t===0?Ai(d,n,r[1]):Ai(d,r[0],l),r}function mv({label:e,value:t,min:a,max:n,step:l=1,onChange:o,lowerLabel:r=`${e}: \u043D\u0438\u0436\u043D\u044F\u044F \u0433\u0440\u0430\u043D\u0438\u0446\u0430`,upperLabel:i=`${e}: \u0432\u0435\u0440\u0445\u043D\u044F\u044F \u0433\u0440\u0430\u043D\u0438\u0446\u0430`,formatValue:u=String,formatLimit:d=String,limitSide:m="right",disabled:f=!1,className:g,style:h,orientation:v,...S}){let C=n>a?n:a+1,x=im(t,a,C),p=(0,Md.useRef)(x);p.current=x;let y=(0,Md.useRef)([]),L=(0,Md.useRef)(null),M=x.map(T=>(T-a)/(C-a)*100),E={...h,"--nodedc-range-lower":`${M[0]}%`,"--nodedc-range-upper":`${M[1]}%`},I=(T,B)=>{let le=cv(p.current,T,B,a,C,l);p.current=le,o(le)},N=T=>{let B=T.currentTarget.getBoundingClientRect();return a+Math.max(0,Math.min(1,(B.bottom-T.clientY)/B.height))*(C-a)},A=T=>{L.current?.id===T.pointerId&&(L.current=null,T.currentTarget.hasPointerCapture(T.pointerId)&&T.currentTarget.releasePointerCapture(T.pointerId))};return(0,Pn.jsxs)("div",{className:"nodedc-range-scale","data-band":"true","data-limit-side":m,"data-disabled":f||void 0,style:E,children:[(0,Pn.jsx)("div",{className:_("nodedc-range",g),"data-orientation":"vertical",children:(0,Pn.jsx)("div",{className:"nodedc-range-band__target",onPointerDown:T=>{if(f||T.button!==0||L.current)return;T.preventDefault(),T.stopPropagation();let B=N(T),le=sv(p.current,B);L.current={id:T.pointerId,boundary:le},y.current[le]?.focus({preventScroll:!0}),T.currentTarget.setPointerCapture(T.pointerId),I(le,B)},onPointerMove:T=>{f||L.current?.id!==T.pointerId||(T.preventDefault(),T.stopPropagation(),I(L.current.boundary,N(T)))},onPointerUp:A,onPointerCancel:A,onLostPointerCapture:()=>{L.current=null},children:[0,1].map(T=>(0,fv.createElement)("input",{...S,key:T,ref:B=>{y.current[T]=B},type:"range","data-boundary":T===0?"lower":"upper",min:a,max:C,step:l,value:x[T],disabled:f,"aria-label":T===0?r:i,"aria-orientation":"vertical","aria-valuemin":T===0?a:x[0],"aria-valuemax":T===0?x[1]:C,"aria-valuetext":u(x[T]),onChange:B=>I(T,Number(B.target.value))}))})}),(0,Pn.jsx)("span",{className:"nodedc-range-scale__limit nodedc-range-scale__limit--max",children:d(x[1])}),(0,Pn.jsx)("span",{className:"nodedc-range-scale__limit nodedc-range-scale__limit--min",children:d(x[0])})]})}var um=(e,t,a)=>Math.max(t,Math.min(a,e)),pv=e=>{let[t,a]=String(e).toLowerCase().split("e"),n=t?.split(".")[1]?.length??0;if(a===void 0)return n;let l=Number.parseInt(a,10);return Number.isFinite(l)?Math.max(0,n-l):n},rw=(e,t,a,n,l)=>{let o=l?.min??Number.NEGATIVE_INFINITY,r=l?.max??Number.POSITIVE_INFINITY,i=um(e,o,r);if(n==="any")return i;let u=n===void 0?1:Number(n);if(!Number.isFinite(u)||u<=0)return i;let d=Math.min(12,Math.max(pv(t),pv(u))),m=t+Math.round((i-t)/u)*u;return um(Number(m.toFixed(d)),o,r)},Di=e=>Number.isInteger(e)?String(e):String(Number(e.toFixed(12)));function iw(e){return Array.isArray(e.value)}function dm(e){return iw(e)?(0,Ue.jsx)(mv,{...e}):(0,Ue.jsx)(uw,{...e})}function uw({label:e,orientation:t="horizontal",value:a,min:n,max:l,exactValueBounds:o,step:r,formatValue:i=String,formatLimit:u=String,limitSide:d="right",onChange:m,className:f,disabled:g=!1,tabIndex:h,...v}){let S=(0,tt.useRef)(null),C=(0,tt.useRef)(null),x=(0,tt.useRef)(null),p=(0,tt.useRef)(!1),[y,L]=(0,tt.useState)(!1),[M,E]=(0,tt.useState)(()=>Di(a)),[I,N]=(0,tt.useState)("base"),A=l===n?n+1:l,T=Math.max(0,Math.min(100,(a-n)/(A-n)*100)),B=i(a),le=Math.max(1,Math.min(14,y?M.length||Di(a).length:B.length)),Bt={"--nodedc-range-progress":`${T}%`,"--nodedc-range-editor-characters":le};(0,tt.useLayoutEffect)(()=>E(Di(a)),[a]),(0,tt.useEffect)(()=>{y||E(Di(a))},[y,a]),(0,tt.useLayoutEffect)(()=>{let X=S.current,Jt=x.current;if(!X||!Jt)return;let vt=()=>{let Re=X.getBoundingClientRect(),ea=Jt.getBoundingClientRect(),so=Number.parseFloat(getComputedStyle(Jt).paddingRight)||0,Fi=Re.left+Re.width*T/100,ji=ea.right-so;N(Fi>=ji?"fill":"base")};vt();let Pe=typeof ResizeObserver>"u"?null:new ResizeObserver(vt);return Pe?.observe(X),()=>Pe?.disconnect()},[le,T]);let yt=(X,Jt)=>{if(X){let vt=Number(M.trim().replace(",","."));Number.isFinite(vt)&&m(rw(vt,n,l,r,o))}L(!1),Jt&&requestAnimationFrame(()=>C.current?.focus())},ge=X=>{X.stopPropagation(),X.key==="Enter"&&(X.preventDefault(),X.currentTarget.blur()),X.key==="Escape"&&(X.preventDefault(),p.current=!0,E(Di(a)),L(!1),X.currentTarget.blur(),requestAnimationFrame(()=>C.current?.focus()))};return t==="vertical"?(0,Ue.jsxs)("div",{className:"nodedc-range-scale","data-limit-side":d,style:Bt,children:[(0,Ue.jsx)("div",{ref:S,className:_("nodedc-range",f),style:Bt,"data-orientation":"vertical",children:(0,Ue.jsx)("input",{ref:C,...v,type:"range",value:a,min:n,max:A,step:r,disabled:g,tabIndex:h,"aria-label":e,"aria-orientation":"vertical","aria-valuetext":B,onChange:X=>m(Number(X.target.value))})}),(0,Ue.jsx)("span",{className:"nodedc-range-scale__limit nodedc-range-scale__limit--max",children:u(um(a,n,A))}),(0,Ue.jsx)("span",{className:"nodedc-range-scale__limit nodedc-range-scale__limit--min",children:u(n)})]}):(0,Ue.jsxs)("div",{ref:S,className:_("nodedc-range",f),style:Bt,"data-editing":y||void 0,children:[(0,Ue.jsx)("input",{ref:C,...v,type:"range",value:a,min:n,max:A,step:r,disabled:g,tabIndex:y?-1:h,"aria-label":e,"aria-valuetext":B,onChange:X=>m(Number(X.target.value))}),(0,Ue.jsx)("span",{className:"nodedc-range__label",children:e}),(0,Ue.jsx)("span",{className:"nodedc-range__value",children:B}),(0,Ue.jsxs)("span",{className:"nodedc-range__fill-text","aria-hidden":"true",children:[(0,Ue.jsx)("span",{className:"nodedc-range__label",children:e}),(0,Ue.jsx)("span",{className:"nodedc-range__value",children:B})]}),(0,Ue.jsx)("input",{ref:x,className:"nodedc-range__editor",type:"text",inputMode:"decimal",value:M,"aria-label":`${e}: \u0442\u043E\u0447\u043D\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435`,disabled:g,spellCheck:!1,"data-active":y||void 0,"data-contrast":I,onFocus:()=>{y||L(!0)},onChange:X=>E(X.target.value),onKeyDown:ge,onBlur:()=>{if(p.current){p.current=!1;return}yt(!0,!1)}})]})}var hv=k(O(),1);var sm=k(O(),1),gv=k(z(),1);var sT=(0,gv.forwardRef)(function({active:t,className:a,type:n="button",...l},o){return(0,sm.jsx)("button",{...l,ref:o,type:n,className:_("nodedc-segmented__item",a),"data-active":t?"true":void 0})});var xv=k(O(),1);function yv({tone:e="neutral",variant:t="badge",pulse:a=!1,className:n,children:l,...o}){return(0,xv.jsx)("span",{className:_("nodedc-status",n),"data-tone":e==="neutral"?void 0:e,"data-variant":t==="indicator"?t:void 0,"data-pulse":a?"true":void 0,...o,children:t==="indicator"?null:l})}var Zl=k(O(),1);function cm({checked:e,label:t,disabled:a=!1,onChange:n}){return(0,Zl.jsxs)("button",{type:"button",className:"nodedc-switch",role:"switch","aria-checked":e,disabled:a,onClick:()=>n(!e),children:[(0,Zl.jsx)("span",{className:"nodedc-switch__track","aria-hidden":"true",children:(0,Zl.jsx)("span",{})}),(0,Zl.jsx)("span",{children:t})]})}var fm=k(O(),1),mm=k(z(),1);var Lv=k(O(),1),Ad=k(z(),1);var vv=k(z(),1);var bv=k(O(),1),Sv=k(z(),1),mw=k(Gt(),1);var pm=k(O(),1);var Cv=k(O(),1),Dd=k(z(),1);var wv=k(O(),1),gm=k(z(),1);var hm=k(O(),1),Td=k(z(),1);var QT=["image/png","image/jpeg","image/gif","image/webp","image/avif","video/mp4","video/webm","video/quicktime",".png",".jpg",".jpeg",".gif",".webp",".avif",".mp4",".webm",".mov"].join(",");var pw=k(O(),1),xm=k(z(),1);var Iv=k(O(),1);var kv=k(O(),1),Ev=k(z(),1);var hw=(0,Ev.forwardRef)(function({pressed:t=!1,label:a,children:n,className:l,type:o="button",disabled:r,...i},u){return(0,kv.jsx)("button",{...i,ref:u,type:o,disabled:r,"aria-label":a,title:a,"aria-pressed":t&&!r,className:_("nodedc-key-button",l),children:n})});var Mv=k(O(),1),ym=k(z(),1);var Av=k(O(),1),gw=k(z(),1);var Dv=k(O(),1),Tv=k(z(),1);var xw=(0,Tv.forwardRef)(function({className:t,...a},n){return(0,Dv.jsx)(un,{...a,ref:n,variant:"ghost",size:"dense",className:_("nodedc-scene-annotation",t)})});var Nv=k(O(),1);function Rv({root:e,navigationOpen:t=!1,activeView:a=null,contentExpanded:n=!0,onChange:l}={}){let o={navigationOpen:t||a!==null,activeView:a,contentOpen:a!==null,contentExpanded:n},r=i=>{o={...o,...i},o.contentOpen=o.activeView!==null,e?.toggleAttribute("data-navigation-open",o.navigationOpen),e?.toggleAttribute("data-content-open",o.contentOpen),e?.toggleAttribute("data-content-expanded",o.contentOpen&&o.contentExpanded),l?.({...o})};return r({}),{getState:()=>({...o}),openNavigation:()=>r({navigationOpen:!0}),toggleNavigation:()=>r({navigationOpen:!o.navigationOpen,activeView:o.navigationOpen?null:o.activeView}),closeNavigation:()=>r({navigationOpen:!1,activeView:null}),openView:i=>r({navigationOpen:!0,activeView:i,contentExpanded:!0}),closeView:()=>r({activeView:null}),setContentExpanded:i=>r({contentExpanded:i})}}var Bv=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])","[tabindex]:not([tabindex='-1'])"].join(",");function vm({overlay:e,dialog:t,closeControls:a=[],closeOnBackdrop:n=!0,closeOnEscape:l=!0,lockBodyScroll:o=!0,onOpenChange:r}){let i=!1,u=null,d="",m=Array.from(a);e.classList.add("nodedc-overlay","nodedc-ui-root"),t.classList.add("nodedc-window"),t.setAttribute("role","dialog"),t.setAttribute("aria-modal","true"),t.tabIndex=-1,e.hidden=!0;let f=()=>{(t.querySelector(Bv)??t).focus()},g=()=>{i||(i=!0,u=document.activeElement instanceof HTMLElement?document.activeElement:null,d=document.body.style.overflow,o&&(document.body.style.overflow="hidden"),e.hidden=!1,requestAnimationFrame(f),r?.(!0))},h=()=>{i&&(i=!1,e.hidden=!0,o&&(document.body.style.overflow=d),u?.focus(),r?.(!1))},v=C=>{n&&C.target===e&&h()},S=C=>{if(!i)return;if(C.key==="Escape"&&l){C.preventDefault(),h();return}if(C.key!=="Tab")return;let x=Array.from(t.querySelectorAll(Bv));if(x.length===0){C.preventDefault(),t.focus();return}let p=x[0],y=x[x.length-1];C.shiftKey&&document.activeElement===p?(C.preventDefault(),y.focus()):!C.shiftKey&&document.activeElement===y&&(C.preventDefault(),p.focus())};return e.addEventListener("pointerdown",v),document.addEventListener("keydown",S),m.forEach(C=>C.addEventListener("click",h)),{open:g,close:h,isOpen:()=>i,destroy:()=>{h(),e.removeEventListener("pointerdown",v),document.removeEventListener("keydown",S),m.forEach(C=>C.removeEventListener("click",h))}}}var Ee=_v.default.createElement,R=(e,t=document)=>t.querySelector(e),ce=(e,t=document)=>[...t.querySelectorAll(e)],Ql=e=>R(`#ds-${e}`).content.firstElementChild.cloneNode(!0);function He(e,t){e&&e.classList.add(...t.split(" "))}var Ni=new Map,Ti=[],Lm=!1,bm,yw=0;function cn(){Lm||(Lm=!0,queueMicrotask(()=>{Lm=!1,Sm()}))}function Fn(e){let t=Ni.get(e);if(!t){let a=document.createElement("span");a.className="cms-ui-island",e.after(a),e.hidden=!0,e.tabIndex=-1,e.setAttribute("aria-hidden","true"),t={host:a,root:(0,Ov.createRoot)(a),signature:""},Ni.set(e,t)}return t}function vw(){for(let e of ce("select")){let t=Fn(e),a=[...e.options].map(r=>({value:r.value,label:r.textContent,disabled:r.disabled})),n=e.getAttribute("aria-label")||e.closest("label")?.querySelector(".nodedc-field__label")?.textContent||"\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435",l=JSON.stringify([e.value,a,e.disabled,n]);if(l===t.signature)continue;t.signature=l,(0,fn.flushSync)(()=>t.root.render(Ee(Mi,{value:e.value,options:a,label:n,disabled:e.disabled,onChange:r=>{e.value=r,e.dispatchEvent(new Event("input",{bubbles:!0})),e.dispatchEvent(new Event("change",{bubbles:!0})),cn()}}))),e.id&&e.closest("label")?.setAttribute("for",e.id+"-trigger");let o=R("button",t.host);o&&e.id&&(o.id=e.id+"-trigger")}}function Lw(){for(let e of ce("input[type=checkbox]")){let t=e.closest("label")||e.parentElement,a=Ni.get(e);if(!a){let l=t.querySelector(".field-label-text")?.textContent||[...t.childNodes].filter(o=>o!==e).map(o=>o.textContent).join(" ").trim()||e.getAttribute("aria-label")||"\u0412\u043A\u043B\u044E\u0447\u0435\u043D\u043E";a=Fn(e),a.label=l.replace(/\s+/g," ").trim();for(let o of[...t.childNodes])o!==e&&o!==a.host&&!(o.nodeType===1&&o.matches("input,select,textarea"))&&(o.nodeType===1?o.hidden=!0:o.nodeType===3&&(o.textContent=""));t.classList.contains("link-mode-row")||t.classList.add("cms-switch-binding");for(let o of ce("input:not([type=checkbox])",t))o.setAttribute("aria-label",a.label);t.addEventListener("click",o=>{o.target.closest("button")&&o.preventDefault()})}let n=JSON.stringify([e.checked,e.disabled]);n!==a.signature&&(a.signature=n,(0,fn.flushSync)(()=>a.root.render(Ee(cm,{checked:e.checked,disabled:e.disabled,label:a.label,onChange:l=>{e.checked=l,e.dispatchEvent(new Event("input",{bubbles:!0})),e.dispatchEvent(new Event("change",{bubbles:!0})),cn()}}))))}}function bw(){for(let e of ce("input[type=range]")){if(e.closest(".cms-ui-island"))continue;let t=Fn(e),a=e.closest(".range-field"),n=a?.querySelector(".range-value");n&&(n.hidden=!0);let l=a?.querySelector(".field-label-text")?.textContent||"\u0417\u043D\u0430\u0447\u0435\u043D\u0438\u0435",o=JSON.stringify([e.value,e.min,e.max,e.step,e.disabled]);if(o===t.signature)continue;t.signature=o;let r=Number(e.min),i=Number(e.max);(0,fn.flushSync)(()=>t.root.render(Ee(dm,{label:l,value:Number(e.value),min:r,max:i,step:e.step,exactValueBounds:{min:r,max:i},disabled:e.disabled,onChange:u=>{e.value=String(u),e.dispatchEvent(new Event("input",{bubbles:!0})),cn()}})))}}function Sw(){for(let e of ce(".publish-progress-track")){let t=Fn(e),a=Number(e.getAttribute("aria-valuenow")||0);t.signature!==String(a)&&(t.signature=String(a),(0,fn.flushSync)(()=>t.root.render(Ee(Ii,{label:"\u041F\u0440\u043E\u0433\u0440\u0435\u0441\u0441 \u043F\u0443\u0431\u043B\u0438\u043A\u0430\u0446\u0438\u0438",value:a/100}))))}}function Cw(){for(let e of ce(".field-control:not(.boolean-field):not(.service-media-field),.json-field,.media-search,.site-dialog label")){if(e.dataset.dsField)continue;e.dataset.dsField="true",He(e,"nodedc-field");let t=R(":scope > .field-label-row",e),a=t?.querySelector(".field-label-text")||R(":scope > span:not(.field-kind):not(.field-path):not(.field-hint)",e);if(!t){if(t=Ql("field").querySelector(".nodedc-field__label-row"),a)t.querySelector(".nodedc-field__label").replaceWith(a);else{a=t.querySelector(".nodedc-field__label"),a.textContent=[...e.childNodes].filter(l=>l.nodeType===3).map(l=>l.textContent).join(" ").trim();for(let l of[...e.childNodes])l.nodeType===3&&(l.textContent="")}e.prepend(t)}He(t,"nodedc-field__label-row"),He(a||R(".field-label-text",t),"nodedc-field__label");let n=R("input:not([type=hidden]):not([type=checkbox]),textarea,select",e);n&&!n.id&&(n.id="cms-field-"+ ++yw),n&&e.tagName==="LABEL"&&(e.htmlFor=n.id);for(let l of ce(".field-hint,.group-desc",e))He(l,"nodedc-field__description")}for(let e of ce("input:not([type=hidden]):not([type=checkbox]):not([type=file]):not([type=range]),textarea"))e.closest(".cms-ui-island")||He(e,"nodedc-field__control")}function ww(){for(let e of ce(".settings-card,.content-group,.content-panel")){if(e.dataset.dsCard)continue;e.dataset.dsCard="true",He(e,"nodedc-settings-card");let t=R(":scope > .card-head,:scope > .group-head,:scope > .panel-head,:scope > .publish-progress-head",e),a=Ql("card"),n=R(".nodedc-settings-card__head",a),l=R(".nodedc-settings-card__titles",a),o=R(".nodedc-settings-card__body",a);if(n.replaceChildren(l),l.replaceChildren(),o.replaceChildren(),t){let r=R("h3,h2",t)||t,i=R(".section-kicker",t);if(i&&l.append(i),r?.hasAttribute("data-publish-title"))l.append(r);else if(r===t){let d=document.createElement("h2");for(let m of[...r.childNodes])(m.nodeType===3||m.nodeType===1&&!m.matches("label,button"))&&d.append(m);l.append(d);for(let m of[...r.children])n.append(m)}else if(r){let d=document.createElement("h2");for(let m of r.attributes)d.setAttribute(m.name,m.value);d.append(...r.childNodes),l.append(d)}let u=R(".project-settings-hint,.panel-note,.group-desc",t)||R(":scope > .group-desc",e);if(u){let d=document.createElement("p");for(let m of u.attributes)d.setAttribute(m.name,m.value);d.classList.add("nodedc-description"),d.append(...u.childNodes),u.remove(),l.append(d)}for(let d of ce(":scope > .toggle-row,:scope > .button-row,:scope > .group-head-toggle,:scope > [data-publish-percent]",t))n.append(d);t.remove()}else n.remove();o.append(...e.childNodes),e.append(...a.childNodes)}}var Iw={"move-up":"chevron-up","move-down":"chevron-down",duplicate:"copy",copy:"copy","paste-after":"clipboard","delete-block":"trash","template-modal-close":"close","media-modal-close":"close","media-trash-toggle":"trash","media-delete":"trash"};function kw(){for(let e of ce("button")){if(e.closest(".cms-ui-island")||e.className.includes("nodedc-")||e.matches(".media-entry,.knowledge-tree-select,.service-media-source-button,.service-media-file-button,.media-breadcrumb-button,.template-card"))continue;let t=e.matches(".icon-action-btn,.collection-icon-btn,.knowledge-tree-action,.secret-toggle-button,.collection-drag-handle,.modal-close-button,.media-header-action"),a=Ql(t?"iconButton":"button");if(He(e,a.className),t){let n=e.getAttribute("aria-label")||e.title||e.textContent;e.setAttribute("aria-label",n),e.title=n;let l=Iw[e.id]||(e.classList.contains("secret-toggle-button")?"eye":/удал/i.test(n)?"trash":/добав/i.test(n)?"plus":/выше|вверх/i.test(n)?"chevron-up":/ниже|вниз/i.test(n)?"chevron-down":/коп/i.test(n)?"copy":"move");e.replaceChildren(Ql("icon-"+l))}else{e.dataset.variant=e.matches(".primary-btn,[type=submit]")?"primary":e.matches(".danger-btn")?"danger":"secondary",e.dataset.tone="neutral";let n=a.firstElementChild;n.replaceChildren(...e.childNodes),e.append(n)}}}function Ew(){for(let e of ce(".block-btn,.knowledge-tree-select")){He(e,"nodedc-admin-panel__nav-item"),e.dataset.active=String(e.classList.contains("active")||e.closest(".knowledge-tree-row")?.dataset.active==="true");let t=R(".block-name,.knowledge-tree-title",e);t&&(e.title=t.textContent);let a=R(".block-icon,.knowledge-tree-icon",e);a&&!a.dataset.dsIcon&&(a.dataset.dsIcon="true",He(a,"nodedc-admin-panel__nav-icon"),a.replaceChildren(Ql("icon-"+(e.classList.contains("knowledge-tree-select")?"file":"layers"))));let n=R(".block-drag-handle",e);n&&(He(n,"nodedc-drag-handle"),n.dataset.dsIcon||(n.dataset.dsIcon="true",n.replaceChildren(Ql("icon-move"))))}for(let e of ce(".region-title"))He(e,"nodedc-admin-panel__group-label")}function Mw(){for(let e of ce(".knowledge-tree-actions")){let t=ce(":scope > button",e);if(t.length<2)continue;let a=Fn(e),n=e.closest(".knowledge-tree-row")?.querySelector(".knowledge-tree-title")?.textContent||"\u041C\u0430\u0442\u0435\u0440\u0438\u0430\u043B",l=t.map(r=>({label:r.title||r.getAttribute("aria-label"),disabled:r.disabled})),o=JSON.stringify([n,l]);o!==a.signature&&(a.signature=o,(0,fn.flushSync)(()=>a.root.render(Ee(dn,{minWidth:240,placement:"bottom-end",trigger:r=>Ee(qt,{label:"\u0414\u0435\u0439\u0441\u0442\u0432\u0438\u044F: "+n,ref:i=>{r.setAnchorRef(i),r.setTriggerRef(i)},onClick:r.toggle,"aria-expanded":r.open,"aria-controls":r.surfaceId,"aria-haspopup":"menu"},Ee(ve,{name:"chevron-down"}))},({close:r})=>t.map((i,u)=>Ee("button",{key:u,type:"button",role:"menuitem",className:"nodedc-dropdown-option",disabled:i.disabled,onClick:()=>{r(),i.click()}},Ee("span",null),Ee("span",{className:"nodedc-dropdown-option__body"},Ee("span",{className:"nodedc-dropdown-option__label"},l[u].label))))))))}}function Aw(){let e=matchMedia("(max-width:760px)").matches,t=R("#dirty-state"),a=Fn(t),n=t.dataset.dirty==="true"?"warning":"neutral",l=t.textContent,o=JSON.stringify([n,l,e]);a.signature!==o&&(a.signature=o,(0,fn.flushSync)(()=>a.root.render(Ee(yv,{tone:n,variant:e?"indicator":"badge",title:l,"aria-label":l,role:"status"},e?null:l))));let r=R("#cms-mobile-actions-binding");r||(r=document.createElement("span"),r.id="cms-mobile-actions-binding",R(".cms-editor-actions").append(r));let i=Fn(r),u=["reload","render","publish"].map(f=>R("#"+f));for(let f of u)f.hidden=e;if(i.host.hidden=!e,!e)return;let d=u.filter(f=>!f.classList.contains("hidden")).map(f=>({button:f,label:f.id==="reload"?"\u041F\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0434\u0430\u043D\u043D\u044B\u0435":f.textContent,disabled:f.disabled})),m=JSON.stringify(d.map(({label:f,disabled:g})=>[f,g]));i.signature!==m&&(i.signature=m,(0,fn.flushSync)(()=>i.root.render(Ee(dn,{minWidth:240,placement:"bottom-end",trigger:f=>Ee(qt,{label:"\u0414\u0435\u0439\u0441\u0442\u0432\u0438\u044F \u0441 \u0441\u0430\u0439\u0442\u043E\u043C",ref:g=>{f.setAnchorRef(g),f.setTriggerRef(g)},onClick:f.toggle,"aria-expanded":f.open,"aria-controls":f.surfaceId,"aria-haspopup":"menu"},Ee(ve,{name:"chevron-down"}))},({close:f})=>d.map(({button:g,label:h,disabled:v})=>Ee("button",{key:g.id,type:"button",role:"menuitem",className:"nodedc-dropdown-option",disabled:v,onClick:()=>{f(),g.click()}},Ee("span",null),Ee("span",{className:"nodedc-dropdown-option__body"},Ee("span",{className:"nodedc-dropdown-option__label"},h))))))))}function Dw(){let e={".service-media-field":"nodedc-media-field",".field-label-row":"nodedc-media-field__label-row",".field-label-text":"nodedc-media-field__label",".service-media-control":"nodedc-media-control",".service-media-file-control":"nodedc-media-file",".service-media-file-button":"nodedc-media-file__button",".service-media-file-name":"nodedc-media-file__name",".service-media-url-input":"nodedc-media-url",".service-media-source-switch":"nodedc-media-source-switch",".service-media-source-button":"nodedc-media-source-button",".service-media-preview":"nodedc-media-preview",".media-upload-hint":"nodedc-media-field__hint",".media-upload-error":"nodedc-media-field__error"};for(let t of ce(".service-media-field")){for(let[n,l]of Object.entries(e))for(let o of t.matches(n)?[t]:ce(n,t))He(o,l);for(let n of ce(".service-media-source-button",t))n.setAttribute("aria-pressed",n.dataset.active);let a=R(".service-media-control",t);a&&(a.dataset.source=R(".service-media-url-input",t).hidden?"file":"url")}}function Tw(){for(let e of ce(".template-modal-layer")){let t=R(":scope > article",e),a=R(":scope > header",t),n=R(":scope > footer",t),l=document.createElement("div");l.className="nodedc-window__body";for(let i of[...t.children])i!==a&&i!==n&&l.append(i);a&&(He(a,"nodedc-window__head"),He(R("h2",a),"nodedc-window__title")),n&&He(n,"nodedc-window__footer"),t.replaceChildren(...[a,l,n].filter(Boolean)),t.dataset.size=e.id==="media-modal"||e.id==="template-modal"?"lg":"sm",He(t,"nodedc-glass nodedc-material-rim"),t.dataset.tone="strong";let o=e.getAttribute("aria-labelledby");o&&t.setAttribute("aria-labelledby",o),e.removeAttribute("role"),e.removeAttribute("aria-modal");let r=vm({overlay:e,dialog:t,closeOnBackdrop:!1,closeOnEscape:!1,lockBodyScroll:!1});Ti.push({overlay:e,dialog:t,controller:r})}for(let e of ce("dialog.site-dialog")){let t=document.createElement("div");t.className="hidden",e.before(t),t.append(e),e.setAttribute("open",""),e.dataset.size="sm",He(e,"nodedc-glass nodedc-material-rim"),e.dataset.tone="strong";let a=R("form",e),n=document.createElement("header"),l=document.createElement("div"),o=R(".site-dialog-actions",a);n.className="nodedc-window__head",l.className="nodedc-window__body";let r=document.createElement("div");r.className="nodedc-window__titles",n.append(r);let i=R("h2",a);i.id=e.id+"-title",e.setAttribute("aria-labelledby",i.id),i.className="nodedc-window__title",r.append(i),l.append(...[...a.childNodes].filter(m=>m!==o)),o.classList.add("nodedc-window__footer"),a.replaceChildren(n,l,o);let u,d=vm({overlay:t,dialog:e,closeOnEscape:!0,lockBodyScroll:!1,onOpenChange:m=>{t.classList.toggle("hidden",!m),m||requestAnimationFrame(()=>u?.focus())}});e.showModal=()=>{u=document.activeElement,document.body.append(t),t.classList.remove("hidden"),d.open()},e.close=()=>{t.classList.add("hidden"),d.close()},Ti.push({overlay:t,dialog:e,controller:d})}}function Sm(){bm?.disconnect();try{for(let[l,o]of Ni)l.isConnected||(o.root.unmount(),o.host.remove(),Ni.delete(l));ww(),Cw(),Lw(),vw(),bw(),Sw(),kw(),Ew(),Mw(),Aw(),Dw(),R("#cms-shell").inert=!1;for(let l of Ti)l.dialog.inert=!1;for(let l of Ti){let o=!l.overlay.classList.contains("hidden");o&&!l.controller.isOpen()?(document.body.append(l.overlay),l.controller.open()):!o&&l.controller.isOpen()&&l.controller.close()}let e=ce(".nodedc-overlay:not(.hidden):not([hidden])").at(-1);R("#cms-shell").inert=!!e;for(let l of Ti)l.dialog.inert=!!(e&&l.overlay!==e);R("#delete-modal-body").textContent==="\u0412\u044B \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043B\u044C\u043D\u043E \u043F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044C \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u0435 \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430?"&&(R("#delete-modal-body").textContent="\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u044B\u0439 \u044D\u043B\u0435\u043C\u0435\u043D\u0442?"),R("#delete-modal-confirm").textContent.trim()==="\u0414\u0430"&&(R("#delete-modal-confirm").textContent="\u0423\u0434\u0430\u043B\u0438\u0442\u044C");let t=R("#add-block"),a=t?.querySelector(".nodedc-button__content");if(a){let l=R("#admin-mode-knowledge").dataset.active==="true"?"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0440\u0430\u0437\u0434\u0435\u043B":"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0431\u043B\u043E\u043A";a.lastChild.textContent.trim()!==l&&(a.lastChild.textContent=l)}let n=R("#dirty-state");n.dataset.tone=n.dataset.dirty==="true"?"warning":"neutral";for(let l of ce(".nodedc-header__nav-item"))l.dataset.active==="true"?l.setAttribute("aria-current","page"):l.removeAttribute("aria-current")}finally{bm?.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["class","disabled","data-dirty","data-active","hidden","aria-valuenow"]})}}function zv(){Jf(document.documentElement,{theme:"dark"});for(let a of ce("[data-cms-mode]"))a.closest("button").id="admin-mode-"+a.dataset.cmsMode;R(".nodedc-header-navigation").classList.add("nodedc-expanded-nav-group"),R(".nodedc-admin-panel__nav").id="regions",R(".nodedc-application-panel__titles h1").id="selected-title",R(".nodedc-application-panel__titles p").id="selected-region",R("#status").setAttribute("role","status"),R("#status").setAttribute("aria-live","polite");let e=R("#cms-shell"),t=Rv({navigationOpen:!0,activeView:"cms",contentExpanded:!0,onChange:a=>{R(".cms-stage").hidden=a.navigationOpen||a.contentOpen,e.dataset.navigationOpen=String(a.navigationOpen),e.dataset.contentOpen=String(a.contentOpen),e.dataset.contentExpanded=String(a.contentExpanded),R(".nodedc-app-shell__navigation").hidden=!a.navigationOpen,R(".nodedc-app-shell__navigation").inert=matchMedia("(max-width:760px)").matches&&a.contentOpen,R(".nodedc-app-shell__content").hidden=!a.contentOpen}});matchMedia("(max-width:760px)").addEventListener("change",a=>{R(".nodedc-app-shell__navigation").inert=a.matches&&t.getState().contentOpen,cn()}),R("#toggle-navigation").onclick=()=>{matchMedia("(max-width:760px)").matches&&t.getState().contentOpen&&t.closeView(),t.openNavigation()},R("#open-navigation").onclick=()=>t.openNavigation(),R(".nodedc-admin-panel__close").onclick=()=>t.closeNavigation(),R(".nodedc-application-panel [data-action=close]").onclick=()=>{t.closeView(),t.openNavigation()},document.addEventListener("click",a=>{a.target.closest(".block-btn,.knowledge-tree-select,#project-settings,#admin-mode-content,#admin-mode-seo,#admin-mode-knowledge")&&(t.openView("cms"),queueMicrotask(()=>R(".nodedc-application-panel__body").scrollTop=0)),cn()}),document.addEventListener("input",cn),document.addEventListener("change",cn),Tw(),Sm(),bm=new MutationObserver(cn),Sm()}zv();await Promise.resolve().then(()=>(db(),P2));