@kition/kit-layout-ui 0.1.3 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -49,4 +49,4 @@ Error generating stack: `+n.message+`
49
49
  `).replace(JM,"")}function eh(e,a){return a=Wd(a),Wd(e)===a}function Qe(e,a,t,n,i,r){switch(t){case"children":if(typeof n=="string")a==="body"||a==="textarea"&&n===""||wl(e,n);else if(typeof n=="number"||typeof n=="bigint")a!=="body"&&wl(e,""+n);else return;break;case"className":Rs(e,"class",n);break;case"tabIndex":Rs(e,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":Rs(e,t,n);break;case"style":Z0(e,n,r);return;case"data":if(a!=="object"){Rs(e,"data",n);break}case"src":case"href":if(n===""&&(a!=="a"||t!=="href")){e.removeAttribute(t);break}if(n==null||typeof n=="function"||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(t);break}n=Ls(n),e.setAttribute(t,n);break;case"action":case"formAction":if(typeof n=="function"){e.setAttribute(t,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof r=="function"&&(t==="formAction"?(a!=="input"&&Qe(e,a,"name",i.name,i,null),Qe(e,a,"formEncType",i.formEncType,i,null),Qe(e,a,"formMethod",i.formMethod,i,null),Qe(e,a,"formTarget",i.formTarget,i,null)):(Qe(e,a,"encType",i.encType,i,null),Qe(e,a,"method",i.method,i,null),Qe(e,a,"target",i.target,i,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(t);break}n=Ls(n),e.setAttribute(t,n);break;case"onClick":n!=null&&(e.onclick=zt);return;case"onScroll":n!=null&&Be("scroll",e);return;case"onScrollEnd":n!=null&&Be("scrollend",e);return;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(c(61));if(t=n.__html,t!=null){if(i.children!=null)throw Error(c(60));(r!=null?r.__html:void 0)!==t&&(e.innerHTML=t)}}break;case"multiple":e.multiple=n&&typeof n!="function"&&typeof n!="symbol";break;case"muted":e.muted=n&&typeof n!="function"&&typeof n!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(n==null||typeof n=="function"||typeof n=="boolean"||typeof n=="symbol"){e.removeAttribute("xlink:href");break}t=Ls(n),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",t);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(t,n):e.removeAttribute(t);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"credentialless":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(t,""):e.removeAttribute(t);break;case"capture":case"download":n===!0?e.setAttribute(t,""):n!==!1&&n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(t,n):e.removeAttribute(t);break;case"cols":case"rows":case"size":case"span":n!=null&&typeof n!="function"&&typeof n!="symbol"&&!isNaN(n)&&1<=n?e.setAttribute(t,n):e.removeAttribute(t);break;case"rowSpan":case"start":n==null||typeof n=="function"||typeof n=="symbol"||isNaN(n)?e.removeAttribute(t):e.setAttribute(t,n);break;case"popover":Be("beforetoggle",e),Be("toggle",e),Os(e,"popover",n);break;case"xlinkActuate":Yt(e,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":Yt(e,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":Yt(e,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":Yt(e,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":Yt(e,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":Yt(e,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":Yt(e,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":Yt(e,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":Yt(e,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":Os(e,"is",n);break;case"innerText":case"textContent":return;default:if(!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")t=p3.get(t)||t,Os(e,t,n);else return}$e=!0}function qo(e,a,t,n,i,r){switch(t){case"style":Z0(e,n,r);return;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(c(61));if(t=n.__html,t!=null){if(i.children!=null)throw Error(c(60));(r!=null?r.__html:void 0)!==t&&(e.innerHTML=t)}}break;case"children":if(typeof n=="string")wl(e,n);else if(typeof n=="number"||typeof n=="bigint")wl(e,""+n);else return;break;case"onScroll":n!=null&&Be("scroll",e);return;case"onScrollEnd":n!=null&&Be("scrollend",e);return;case"onClick":n!=null&&(e.onclick=zt);return;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":return;case"innerText":case"textContent":return;default:if(!U0.hasOwnProperty(t))e:{if(t[0]==="o"&&t[1]==="n"&&(i=t.endsWith("Capture"),r=t.slice(2,i?t.length-7:void 0),a=e[Ga]||null,a=a!=null?a[t]:null,typeof a=="function"&&e.removeEventListener(r,a,i),typeof n=="function")){typeof a!="function"&&a!==null&&(t in e?e[t]=null:e.hasAttribute(t)&&e.removeAttribute(t)),e.addEventListener(r,n,i);break e}$e=!0,t in e?e[t]=n:n===!0?e.setAttribute(t,""):Os(e,t,n)}return}$e=!0}function ja(e,a,t){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Be("error",e),Be("load",e);var n=!1,i=!1,r;for(r in t)if(t.hasOwnProperty(r)){var m=t[r];if(m!=null)switch(r){case"src":n=!0;break;case"srcSet":i=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(c(137,a));default:Qe(e,a,r,m,t,null)}}i&&Qe(e,a,"srcSet",t.srcSet,t,null),n&&Qe(e,a,"src",t.src,t,null);return;case"input":Be("invalid",e);var S=r=m=i=null,A=null,V=null;for(n in t)if(t.hasOwnProperty(n)){var K=t[n];if(K!=null)switch(n){case"name":i=K;break;case"type":m=K;break;case"checked":A=K;break;case"defaultChecked":V=K;break;case"value":r=K;break;case"defaultValue":S=K;break;case"children":case"dangerouslySetInnerHTML":if(K!=null)throw Error(c(137,a));break;default:Qe(e,a,n,K,t,null)}}$0(e,r,S,A,V,m,i,!1);return;case"select":Be("invalid",e),n=m=r=null;for(i in t)if(t.hasOwnProperty(i)&&(S=t[i],S!=null))switch(i){case"value":r=S;break;case"defaultValue":m=S;break;case"multiple":n=S;default:Qe(e,a,i,S,t,null)}a=r,t=m,e.multiple=!!n,a!=null?bl(e,!!n,a,!1):t!=null&&bl(e,!!n,t,!0);return;case"textarea":Be("invalid",e),r=i=n=null;for(m in t)if(t.hasOwnProperty(m)&&(S=t[m],S!=null))switch(m){case"value":n=S;break;case"defaultValue":i=S;break;case"children":r=S;break;case"dangerouslySetInnerHTML":if(S!=null)throw Error(c(91));break;default:Qe(e,a,m,S,t,null)}K0(e,n,i,r);return;case"option":for(A in t)if(t.hasOwnProperty(A)&&(n=t[A],n!=null))switch(A){case"selected":e.selected=n&&typeof n!="function"&&typeof n!="symbol";break;default:Qe(e,a,A,n,t,null)}return;case"dialog":Be("beforetoggle",e),Be("toggle",e),Be("cancel",e),Be("close",e);break;case"iframe":case"object":Be("load",e);break;case"video":case"audio":for(n=0;n<Pi.length;n++)Be(Pi[n],e);break;case"image":Be("error",e),Be("load",e);break;case"details":Be("toggle",e);break;case"embed":case"source":case"link":Be("error",e),Be("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(V in t)if(t.hasOwnProperty(V)&&(n=t[V],n!=null))switch(V){case"children":case"dangerouslySetInnerHTML":throw Error(c(137,a));default:Qe(e,a,V,n,t,null)}return;default:if(Gu(a)){for(K in t)t.hasOwnProperty(K)&&(n=t[K],n!==void 0&&qo(e,a,K,n,t,void 0));return}}for(S in t)t.hasOwnProperty(S)&&(n=t[S],n!=null&&Qe(e,a,S,n,t,null))}var PM={};function WM(e,a,t,n){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var i=null,r=null,m=null,S=null,A=null,V=null,K=null;for(X in t){var ee=t[X];if(t.hasOwnProperty(X)&&ee!=null)switch(X){case"checked":break;case"value":break;case"defaultValue":A=ee;default:n.hasOwnProperty(X)||Qe(e,a,X,null,n,ee)}}for(var _ in n){var X=n[_];if(ee=t[_],n.hasOwnProperty(_)&&(X!=null||ee!=null))switch(_){case"type":X!==ee&&($e=!0),r=X;break;case"name":X!==ee&&($e=!0),i=X;break;case"checked":X!==ee&&($e=!0),V=X;break;case"defaultChecked":X!==ee&&($e=!0),K=X;break;case"value":X!==ee&&($e=!0),m=X;break;case"defaultValue":X!==ee&&($e=!0),S=X;break;case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(c(137,a));break;default:X!==ee&&Qe(e,a,_,X,n,ee)}}Vu(e,m,S,A,V,K,r,i);return;case"select":X=m=S=_=null;for(r in t)if(A=t[r],t.hasOwnProperty(r)&&A!=null)switch(r){case"value":break;case"multiple":X=A;default:n.hasOwnProperty(r)||Qe(e,a,r,null,n,A)}for(i in n)if(r=n[i],A=t[i],n.hasOwnProperty(i)&&(r!=null||A!=null))switch(i){case"value":r!==A&&($e=!0),_=r;break;case"defaultValue":r!==A&&($e=!0),S=r;break;case"multiple":r!==A&&($e=!0),m=r;default:r!==A&&Qe(e,a,i,r,n,A)}a=S,t=m,n=X,_!=null?bl(e,!!t,_,!1):!!n!=!!t&&(a!=null?bl(e,!!t,a,!0):bl(e,!!t,t?[]:"",!1));return;case"textarea":X=_=null;for(S in t)if(i=t[S],t.hasOwnProperty(S)&&i!=null&&!n.hasOwnProperty(S))switch(S){case"value":break;case"children":break;default:Qe(e,a,S,null,n,i)}for(m in n)if(i=n[m],r=t[m],n.hasOwnProperty(m)&&(i!=null||r!=null))switch(m){case"value":i!==r&&($e=!0),_=i;break;case"defaultValue":i!==r&&($e=!0),X=i;break;case"children":break;case"dangerouslySetInnerHTML":if(i!=null)throw Error(c(91));break;default:i!==r&&Qe(e,a,m,i,n,r)}X0(e,_,X);return;case"option":for(var fe in t)if(_=t[fe],t.hasOwnProperty(fe)&&_!=null&&!n.hasOwnProperty(fe))switch(fe){case"selected":e.selected=!1;break;default:Qe(e,a,fe,null,n,_)}for(A in n)if(_=n[A],X=t[A],n.hasOwnProperty(A)&&_!==X&&(_!=null||X!=null))switch(A){case"selected":_!==X&&($e=!0),e.selected=_&&typeof _!="function"&&typeof _!="symbol";break;default:Qe(e,a,A,_,n,X)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var be in t)_=t[be],t.hasOwnProperty(be)&&_!=null&&!n.hasOwnProperty(be)&&Qe(e,a,be,null,n,_);for(V in n)if(_=n[V],X=t[V],n.hasOwnProperty(V)&&_!==X&&(_!=null||X!=null))switch(V){case"children":case"dangerouslySetInnerHTML":if(_!=null)throw Error(c(137,a));break;default:Qe(e,a,V,_,n,X)}return;default:if(Gu(a)){for(var He in t)_=t[He],t.hasOwnProperty(He)&&_!==void 0&&!n.hasOwnProperty(He)&&qo(e,a,He,void 0,n,_);for(K in n)_=n[K],X=t[K],!n.hasOwnProperty(K)||_===X||_===void 0&&X===void 0||qo(e,a,K,_,n,X);return}}for(var B in t)_=t[B],t.hasOwnProperty(B)&&_!=null&&!n.hasOwnProperty(B)&&Qe(e,a,B,null,n,_);for(ee in n)_=n[ee],X=t[ee],!n.hasOwnProperty(ee)||_===X||_==null&&X==null||Qe(e,a,ee,_,n,X)}function ah(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function e6(){if(typeof performance.getEntriesByType=="function"){for(var e=0,a=0,t=performance.getEntriesByType("resource"),n=0;n<t.length;n++){var i=t[n],r=i.transferSize,m=i.initiatorType,S=i.duration;if(r&&S&&ah(m)){for(m=0,S=i.responseEnd,n+=1;n<t.length;n++){var A=t[n],V=A.startTime;if(V>S)break;var K=A.transferSize,ee=A.initiatorType;K&&ah(ee)&&(A=A.responseEnd,m+=K*(A<S?1:(S-V)/(A-V)))}if(--n,a+=8*(r+m)/(i.duration/1e3),e++,10<e)break}}if(0<e)return a/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var Go=null,Yo=null;function es(e){return e.nodeType===9?e:e.ownerDocument}function th(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function nh(e,a){if(e===0)switch(a){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&a==="foreignObject"?0:e}function lh(e,a,t,n){return t=es(t).createElement(e),t[Ca]=n,t[Ga]=a,ja(t,e,a),Ma(t),t}function $o(e,a){return e==="textarea"||e==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.children=="bigint"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var Xo=null;function a6(){var e=window.event;return e&&e.type==="popstate"?e===Xo?!1:(Xo=e,!0):(Xo=null,!1)}var Ko=typeof setTimeout=="function"?setTimeout:void 0,t6=typeof clearTimeout=="function"?clearTimeout:void 0,ih=typeof Promise=="function"?Promise:void 0,sh=typeof requestAnimationFrame=="function"?requestAnimationFrame:Ko,n6=typeof queueMicrotask=="function"?queueMicrotask:typeof ih<"u"?function(e){return ih.resolve(null).then(e).catch(l6)}:Ko;function l6(e){setTimeout(function(){throw e})}function En(e){return e==="head"}function rh(e,a){var t=a,n=0;do{var i=t.nextSibling;if(e.removeChild(t),i&&i.nodeType===8)if(t=i.data,t==="/$"||t==="/&"){if(n===0){e.removeChild(i),li(a);return}n--}else if(t==="$"||t==="$?"||t==="$~"||t==="$!"||t==="&")n++;else if(t==="html")e1(e.ownerDocument.documentElement);else if(t==="head"){t=e.ownerDocument.head,e1(t);for(var r=t.firstChild;r;){var m=r.nextSibling,S=r.nodeName;r[gi]||S==="SCRIPT"||S==="STYLE"||S==="LINK"&&r.rel.toLowerCase()==="stylesheet"||t.removeChild(r),r=m}}else t==="body"&&e1(e.ownerDocument.body);t=i}while(t);li(a)}function uh(e,a){var t=e;e=0;do{var n=t.nextSibling;if(t.nodeType===1?a?(t._stashedDisplay=t.style.display,t.style.display="none"):(t.style.display=t._stashedDisplay||"",t.getAttribute("style")===""&&t.removeAttribute("style")):t.nodeType===3&&(a?(t._stashedText=t.nodeValue,t.nodeValue=""):t.nodeValue=t._stashedText||""),n&&n.nodeType===8)if(t=n.data,t==="/$"){if(e===0)break;e--}else t!=="$"&&t!=="$?"&&t!=="$~"&&t!=="$!"||e++;t=n}while(t)}function ch(e,a,t){if(a=CSS.escape(a)!==a?"r-"+btoa(a).replace(/=/g,""):a,e.style.viewTransitionName=a,t!=null&&(e.style.viewTransitionClass=t),t=getComputedStyle(e),t.display==="inline"){if(a=e.getClientRects(),a.length===1)var n=1;else for(var i=n=0;i<a.length;i++){var r=a[i];0<r.width&&0<r.height&&n++}n===1&&(e=e.style,e.display=a.length===1?"inline-block":"block",e.marginTop="-"+t.paddingTop,e.marginBottom="-"+t.paddingBottom)}}function oh(e,a){e=e.style,a=a.style;var t=a!=null?a.hasOwnProperty("viewTransitionName")?a.viewTransitionName:a.hasOwnProperty("view-transition-name")?a["view-transition-name"]:null:null;e.viewTransitionName=t==null||typeof t=="boolean"?"":(""+t).trim(),t=a!=null?a.hasOwnProperty("viewTransitionClass")?a.viewTransitionClass:a.hasOwnProperty("view-transition-class")?a["view-transition-class"]:null:null,e.viewTransitionClass=t==null||typeof t=="boolean"?"":(""+t).trim(),e.display==="inline-block"&&(a==null?e.display=e.margin="":(t=a.display,e.display=t==null||typeof t=="boolean"?"":t,t=a.margin,t!=null?e.margin=t:(t=a.hasOwnProperty("marginTop")?a.marginTop:a["margin-top"],e.marginTop=t==null||typeof t=="boolean"?"":t,a=a.hasOwnProperty("marginBottom")?a.marginBottom:a["margin-bottom"],e.marginBottom=a==null||typeof a=="boolean"?"":a)))}function i6(e,a,t){return t=t.ownerDocument.defaultView,{rect:e,abs:a.position==="absolute"||a.position==="fixed",clip:a.clipPath!=="none"||a.overflow!=="visible"||a.filter!=="none"||a.mask!=="none"||a.mask!=="none"||a.borderRadius!=="0px",view:0<=e.bottom&&0<=e.right&&e.top<=t.innerHeight&&e.left<=t.innerWidth}}function Io(e){var a=e.getBoundingClientRect(),t=getComputedStyle(e);return i6(a,t,e)}function s6(e){return e.documentElement.clientHeight}function r6(e){this.addEventListener("load",e),this.addEventListener("error",e)}function u6(e,a,t,n,i,r,m,S,A){var V=a.nodeType===9?a:a.ownerDocument;try{var K=V.startViewTransition({update:function(){var _=V.defaultView,X=_.navigation&&_.navigation.transition,fe=V.fonts.status;n();var be=[];if(fe==="loaded"&&(s6(V),V.fonts.status==="loading"&&be.push(V.fonts.ready)),fe=be.length,e!==null)for(var He=e.suspenseyImages,B=0,R=0;R<He.length;R++){var Y=He[R];if(!Y.complete){var W=Y.getBoundingClientRect();if(0<W.bottom&&0<W.right&&W.top<_.innerHeight&&W.left<_.innerWidth){if(B+=Nh(Y),B>Yr){be.length=fe;break}Y=new Promise(r6.bind(Y)),be.push(Y)}}}if(0<be.length)return _=Promise.race([Promise.all(be),new Promise(function(Me){return setTimeout(Me,500)})]).then(i,i),(X?Promise.allSettled([X.finished,_]):_).then(r,r);if(i(),X)return X.finished.then(r,r);r()},types:t});V.__reactViewTransition=K;var ee=[];return K.ready.then(function(){for(var _=V.documentElement.getAnimations({subtree:!0}),X=0;X<_.length;X++){var fe=_[X],be=fe.effect,He=be.pseudoElement;if(He!=null&&He.startsWith("::view-transition")){ee.push(fe),fe=be.getKeyframes();for(var B=He=void 0,R=!0,Y=0;Y<fe.length;Y++){var W=fe[Y],Me=W.width;if(He===void 0)He=Me;else if(He!==Me){R=!1;break}if(Me=W.height,B===void 0)B=Me;else if(B!==Me){R=!1;break}delete W.width,delete W.height,W.transform==="none"&&delete W.transform}R&&He!==void 0&&B!==void 0&&(be.setKeyframes(fe),R=getComputedStyle(be.target,be.pseudoElement),R.width!==He||R.height!==B)&&(R=fe[0],R.width=He,R.height=B,R=fe[fe.length-1],R.width=He,R.height=B,be.setKeyframes(fe))}}m()},function(_){V.__reactViewTransition===K&&(V.__reactViewTransition=null);try{if(typeof _=="object"&&_!==null)switch(_.name){case"InvalidStateError":(_.message==="View transition was skipped because document visibility state is hidden."||_.message==="Skipping view transition because document visibility state has become hidden."||_.message==="Skipping view transition because viewport size changed."||_.message==="Transition was aborted because of invalid state")&&(_=null)}_!==null&&A(_)}finally{n(),i(),m()}}),K.finished.finally(function(){for(var _=0;_<ee.length;_++)ee[_].cancel();V.__reactViewTransition===K&&(V.__reactViewTransition=null),S()}),K}catch{return n(),i(),m(),null}}function rl(e,a){this._scope=document.documentElement,this._selector="::view-transition-"+e+"("+a+")"}rl.prototype.animate=function(e,a){return a=typeof a=="number"?{duration:a}:Z({},a),a.pseudoElement=this._selector,this._scope.animate(e,a)},rl.prototype.getAnimations=function(){for(var e=this._scope,a=this._selector,t=e.getAnimations({subtree:!0}),n=[],i=0;i<t.length;i++){var r=t[i].effect;r!==null&&r.target===e&&r.pseudoElement===a&&n.push(t[i])}return n},rl.prototype.getComputedStyle=function(){return getComputedStyle(this._scope,this._selector)};function fh(e){return{name:e,group:new rl("group",e),imagePair:new rl("image-pair",e),old:new rl("old",e),new:new rl("new",e)}}function lt(e){this._fragmentFiber=e,this._observers=this._eventListeners=null}lt.prototype.addEventListener=function(e,a,t){var n=null,i=null;if(!(t!=null&&typeof t!="boolean"&&(n=t.signal||null,n!==null&&n.aborted))){this._eventListeners===null&&(this._eventListeners=[]);var r=this._eventListeners;if(hh(r,e,a,t)===-1){var m=this,S=a;t!=null&&typeof t!="boolean"&&t.once===!0&&(S=function(A){m.removeEventListener(e,a,t),typeof a=="function"?a.call(this,A):a.handleEvent(A)}),n!==null&&(i=m.removeEventListener.bind(m,e,a,t),n.addEventListener("abort",i,{once:!0}),i=n.removeEventListener.bind(n,"abort",i)),n=Pl(t),r.push({type:e,listener:a,optionsOrUseCapture:t,attachedListener:S,cleanup:i}),b(this._fragmentFiber.child,!1,c6,e,S,n)}this._eventListeners=r}};function c6(e,a,t,n){return T(e).addEventListener(a,t,n),!1}lt.prototype.removeEventListener=function(e,a,t){var n=this._eventListeners;if(n!==null&&(a=hh(n,e,a,t),a!==-1)){var i=n[a];t=i.attachedListener;var r=i.cleanup;i=Pl(i.optionsOrUseCapture),b(this._fragmentFiber.child,!1,o6,e,t,i),n.splice(a,1),r!==null&&r()}};function o6(e,a,t,n){return T(e).removeEventListener(a,t,n),!1}function Pl(e){return e!=null&&typeof e!="boolean"&&(e.once===!0||e.signal instanceof AbortSignal)?{capture:e.capture,passive:e.passive}:e}function dh(e){return e==null?"c=0":typeof e=="boolean"?"c="+(e?"1":"0"):"c="+(e.capture?"1":"0")}function hh(e,a,t,n){if(e.length===0)return-1;n=dh(n);for(var i=0;i<e.length;i++){var r=e[i];if(r.type===a&&r.listener===t&&dh(r.optionsOrUseCapture)===n)return i}return-1}lt.prototype.dispatchEvent=function(e){var a=M(this._fragmentFiber);if(a===null)return!0;a=T(a);var t=this._eventListeners;if(t!==null&&0<t.length||!e.bubbles){var n=a.nodeType===9?a.createComment(""):document.createTextNode("");if(t)for(var i=0;i<t.length;i++){var r=t[i];n.addEventListener(r.type,r.attachedListener,Pl(r.optionsOrUseCapture))}if(a.appendChild(n),e=n.dispatchEvent(e),t)for(i=0;i<t.length;i++)r=t[i],n.removeEventListener(r.type,r.attachedListener,Pl(r.optionsOrUseCapture));return a.removeChild(n),e}return a.dispatchEvent(e)},lt.prototype.focus=function(e){b(this._fragmentFiber.child,!0,mh,e,void 0,void 0)};function mh(e,a){return e.tag===6?!1:(e=T(e),S6(e,a))}lt.prototype.focusLast=function(e){var a=[];b(this._fragmentFiber.child,!0,Zo,a,void 0,void 0);for(var t=a.length-1;0<=t&&!mh(a[t],e);t--);};function Zo(e,a){return a.push(e),!1}lt.prototype.blur=function(){var e=M(this._fragmentFiber);e!==null&&(e=T(e),e=es(e).activeElement,e!==null&&b(this._fragmentFiber.child,!1,f6,e,void 0,void 0))};function f6(e,a){return e.tag===6?!1:(e=T(e),e===a||e.contains(a)?(a.blur(),!0):!1)}lt.prototype.observeUsing=function(e){this._observers===null&&(this._observers=new Set),this._observers.add(e),b(this._fragmentFiber.child,!1,d6,e,void 0,void 0)};function d6(e,a){return e.tag===6||(e=T(e),a.observe(e)),!1}lt.prototype.unobserveUsing=function(e){var a=this._observers;if(a!==null&&a.has(e)){a.delete(e),b(this._fragmentFiber.child,!1,h6,e,void 0,void 0);for(var t=a=0;t<bt.length;t++){var n=bt[t];n.fragmentInstance===this&&n.observer===e?e.unobserve(n.instance):bt[a++]=n}bt.length=a}};function h6(e,a){return e.tag===6||(e=T(e),a.unobserve(e)),!1}var bt=[],Fo=!1;function m6(e,a,t){bt.push({fragmentInstance:e,observer:a,instance:t}),Fo||(Fo=!0,z6(function(){Fo=!1;var n=bt;bt=[];for(var i=0;i<n.length;i++){var r=n[i];r.observer.unobserve(r.instance)}}))}lt.prototype.getClientRects=function(){var e=[];return b(this._fragmentFiber.child,!1,v6,e,void 0,void 0),e};function v6(e,a){if(e.tag===6){e=e.stateNode;var t=e.ownerDocument.createRange();t.selectNodeContents(e),a.push.apply(a,t.getClientRects())}else e=T(e),a.push.apply(a,e.getClientRects());return!1}lt.prototype.getRootNode=function(e){var a=M(this._fragmentFiber);return a===null?this:T(a).getRootNode(e)},lt.prototype.compareDocumentPosition=function(e){var a=M(this._fragmentFiber);if(a===null)return Node.DOCUMENT_POSITION_DISCONNECTED;var t=[];b(this._fragmentFiber.child,!1,Zo,t,void 0,void 0);var n=T(a);if(t.length===0){if(t=n,z(this._fragmentFiber)){e:{for(a=this._fragmentFiber.return;a!==null;){if(a.tag===4){a=a.stateNode.containerInfo;break e}if(a.tag===3||a.tag===5||a.tag===27)break;a=a.return}a=null}a!=null&&(t=a)}a=this._fragmentFiber;var i=n=t.compareDocumentPosition(e);return t===e?i=Node.DOCUMENT_POSITION_CONTAINS:n&Node.DOCUMENT_POSITION_CONTAINED_BY&&(t=x(a)[1],t===null?i=Node.DOCUMENT_POSITION_PRECEDING:(e=T(t).compareDocumentPosition(e),i=e===0||e&Node.DOCUMENT_POSITION_FOLLOWING?Node.DOCUMENT_POSITION_FOLLOWING:Node.DOCUMENT_POSITION_PRECEDING)),i|=Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC}a=T(t[0]),i=T(t[t.length-1]);var r=z(this._fragmentFiber)?a.parentElement:n;if(r==null)return Node.DOCUMENT_POSITION_DISCONNECTED;n=r.compareDocumentPosition(a)&Node.DOCUMENT_POSITION_CONTAINED_BY,r=r.compareDocumentPosition(i)&Node.DOCUMENT_POSITION_CONTAINED_BY;var m=a.compareDocumentPosition(e),S=i.compareDocumentPosition(e),A=m&Node.DOCUMENT_POSITION_CONTAINED_BY||S&Node.DOCUMENT_POSITION_CONTAINED_BY;return S=n&&r&&m&Node.DOCUMENT_POSITION_FOLLOWING&&S&Node.DOCUMENT_POSITION_PRECEDING,a=n&&a===e||r&&i===e||A||S?Node.DOCUMENT_POSITION_CONTAINED_BY:!n&&a===e||!r&&i===e?Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:m,a&Node.DOCUMENT_POSITION_DISCONNECTED||a&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC||p6(a,this._fragmentFiber,t[0],t[t.length-1],e)?a:Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC};function p6(e,a,t,n,i){var r=Vn(i);if(e&Node.DOCUMENT_POSITION_CONTAINED_BY){if(t=!!r)e:{for(;r!==null;){if(r.tag===7&&(r===a||r.alternate===a)){t=!0;break e}r=r.return}t=!1}return t}if(e&Node.DOCUMENT_POSITION_CONTAINS){if(r===null)return r=i.ownerDocument,i===r||i===r.documentElement||i===r.body;e:{for(r=a,a=M(a);r!==null;){if(!(r.tag!==5&&r.tag!==3&&r.tag!==27||r!==a&&r.alternate!==a)){r=!0;break e}r=r.return}r=!1}return r}return e&Node.DOCUMENT_POSITION_PRECEDING?((a=!!r)&&!(a=r===t)&&(a=le(t,r,$),a===null?a=!1:(b(a,!0,G,r,t),r=C,C=null,a=r!==null)),a):e&Node.DOCUMENT_POSITION_FOLLOWING?((a=!!r)&&!(a=r===n)&&(a=le(n,r,$),a===null?a=!1:(b(a,!0,J,r,n),r=C,N=C=null,a=r!==null)),a):!1}function vh(e,a){var t=e.ownerDocument.createRange();t.selectNodeContents(e),e=t.getBoundingClientRect(),window.scrollTo(window.scrollX+e.left,a?window.scrollY+e.top:window.scrollY+e.bottom-window.innerHeight)}lt.prototype.scrollIntoView=function(e){if(typeof e=="object")throw Error(c(566));var a=[];b(this._fragmentFiber.child,!1,Zo,a,void 0,void 0);var t=e!==!1;if(a.length===0){var n=x(this._fragmentFiber);if(n=t?n[1]||n[0]||M(this._fragmentFiber):n[0]||n[1],n===null)return;if(n.tag===6){e=T(n),vh(e,t);return}if(n=T(n),n.nodeType!==9){if(n.nodeType===11){t="host"in n?n.host:null,t!==null&&t.scrollIntoView(e);return}n.scrollIntoView(e)}}for(n=t?a.length-1:0;n!==(t?-1:a.length);){var i=a[n];i.tag===6?(i=T(i),vh(i,t)):T(i).scrollIntoView(e),n+=t?-1:1}};function y6(e,a){return e=T(e),ph(e,a),!1}function ph(e,a){e.reactFragments==null&&(e.reactFragments=new Set),e.reactFragments.add(a)}function yh(e,a){var t=a._eventListeners;if(t!==null)for(var n=0;n<t.length;n++){var i=t[n];e.addEventListener(i.type,i.attachedListener,Pl(i.optionsOrUseCapture))}e.nodeType!==3&&(t=a._observers,t!==null&&t.forEach(function(r){for(var m=0,S=0;S<bt.length;S++){var A=bt[S];(A.fragmentInstance!==a||A.observer!==r||A.instance!==e)&&(bt[m++]=A)}bt.length=m,r.observe(e)}),ph(e,a))}function g6(e,a){var t=a._eventListeners;if(t!==null)for(var n=0;n<t.length;n++){var i=t[n];e.removeEventListener(i.type,i.attachedListener,Pl(i.optionsOrUseCapture))}e.nodeType!==3&&(t=a._observers,t!==null&&t.forEach(function(r){typeof r.rootMargin=="string"?m6(a,r,e):r.unobserve(e)}),e.reactFragments!=null&&e.reactFragments.delete(a))}function Qo(e){var a=e.firstChild;for(a&&a.nodeType===10&&(a=a.nextSibling);a;){var t=a;switch(a=a.nextSibling,t.nodeName){case"HTML":case"HEAD":case"BODY":Qo(t),Ns(t);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(t.rel.toLowerCase()==="stylesheet")continue}e.removeChild(t)}}function M6(e,a,t,n){for(;e.nodeType===1;){var i=t;if(e.nodeName.toLowerCase()!==a.toLowerCase()){if(!n&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(n){if(!e[gi])switch(a){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(r=e.getAttribute("rel"),r==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(r!==i.rel||e.getAttribute("href")!==(i.href==null||i.href===""?null:i.href)||e.getAttribute("crossorigin")!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute("title")!==(i.title==null?null:i.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(r=e.getAttribute("src"),(r!==(i.src==null?null:i.src)||e.getAttribute("type")!==(i.type==null?null:i.type)||e.getAttribute("crossorigin")!==(i.crossOrigin==null?null:i.crossOrigin))&&r&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(a==="input"&&e.type==="hidden"){var r=i.name==null?null:""+i.name;if(i.type==="hidden"&&e.getAttribute("name")===r)return e}else return e;if(e=ht(e.nextSibling),e===null)break}return null}function b6(e,a,t){if(a==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=ht(e.nextSibling),e===null))return null;return e}function gh(e,a){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=ht(e.nextSibling),e===null))return null;return e}function Jo(e){return e.data==="$?"||e.data==="$~"}function Po(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function w6(e,a){var t=e.ownerDocument;if(e.data==="$~")e._reactRetry=a;else if(e.data!=="$?"||t.readyState!=="loading")a();else{var n=function(){a(),t.removeEventListener("DOMContentLoaded",n)};t.addEventListener("DOMContentLoaded",n),e._reactRetry=n}}function ht(e){for(;e!=null;e=e.nextSibling){var a=e.nodeType;if(a===1||a===3)break;if(a===8){if(a=e.data,a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"||a==="F!"||a==="F")break;if(a==="/$"||a==="/&")return null}}return e}var Wo=null;function Mh(e){e=e.nextSibling;for(var a=0;e;){if(e.nodeType===8){var t=e.data;if(t==="/$"||t==="/&"){if(a===0)return ht(e.nextSibling);a--}else t!=="$"&&t!=="$!"&&t!=="$?"&&t!=="$~"&&t!=="&"||a++}e=e.nextSibling}return null}function bh(e){e=e.previousSibling;for(var a=0;e;){if(e.nodeType===8){var t=e.data;if(t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"){if(a===0)return e;a--}else t!=="/$"&&t!=="/&"||a++}e=e.previousSibling}return null}function S6(e,a){function t(){n=!0}if(e.ownerDocument.activeElement===e)return!0;var n=!1;try{e.ownerDocument.addEventListener("focus",t,!0),(e.focus||HTMLElement.prototype.focus).call(e,a)}finally{e.ownerDocument.removeEventListener("focus",t,!0)}return n}function z6(e){sh(function(){sh(function(a){return e(a)})})}function wh(e,a,t){switch(a=es(t),e){case"html":if(e=a.documentElement,!e)throw Error(c(452));return e;case"head":if(e=a.head,!e)throw Error(c(453));return e;case"body":if(e=a.body,!e)throw Error(c(454));return e;default:throw Error(c(451))}}function Sh(e,a,t){for(var n in t){var i=t[n];t.hasOwnProperty(n)&&i!=null&&Qe(e,a,n,null,PM,i)}t.dangerouslySetInnerHTML!=null&&(e.textContent=""),e.onclick===zt&&(e.onclick=null),Ns(e)}function e1(e){for(var a=e.attributes;a.length;)e.removeAttributeNode(a[0]);Ns(e)}var mt=new Map,zh=new Set;function as(e){if(typeof e.getRootNode=="function"){var a=e.getRootNode();if(a.nodeType===9||a.nodeType===11)return a}return e.nodeType===9?e:e.ownerDocument}var tn=Te.d;Te.d={f:x6,r:C6,D:E6,C:T6,L:k6,m:A6,X:N6,S:j6,M:O6};function x6(){var e=tn.f(),a=Lr();return e||a}function C6(e){var a=yl(e);a!==null&&a.tag===5&&a.type==="form"?Cf(a):tn.r(e)}var Wl=typeof document>"u"?null:document;function xh(e,a,t){var n=Wl;if(n&&typeof a=="string"&&a){var i=st(a);i='link[rel="'+e+'"][href="'+i+'"]',typeof t=="string"&&(i+='[crossorigin="'+t+'"]'),zh.has(i)||(zh.add(i),e={rel:e,crossOrigin:t,href:a},n.querySelector(i)===null&&(a=n.createElement("link"),ja(a,"link",e),Ma(a),n.head.appendChild(a)))}}function E6(e){tn.D(e),xh("dns-prefetch",e,null)}function T6(e,a){tn.C(e,a),xh("preconnect",e,a)}function k6(e,a,t){tn.L(e,a,t);var n=Wl;if(n&&e&&a){var i='link[rel="preload"][as="'+st(a)+'"]';a==="image"&&t&&t.imageSrcSet?(i+='[imagesrcset="'+st(t.imageSrcSet)+'"]',typeof t.imageSizes=="string"&&(i+='[imagesizes="'+st(t.imageSizes)+'"]')):i+='[href="'+st(e)+'"]';var r=i;switch(a){case"style":r=ei(e);break;case"script":r=ai(e)}if(!(mt.has(r)||(e=Z({rel:"preload",href:a==="image"&&t&&t.imageSrcSet?void 0:e,as:a},t),mt.set(r,e),n.querySelector(i)!==null||a==="style"&&n.querySelector(ts(r))||a==="script"&&n.querySelector(ns(r))))){var m=n.createElement("link");ja(m,"link",e),a==="style"&&(m[js]=!0,m.onload=m.onerror=function(){H0(m)}),Ma(m),n.head.appendChild(m)}}}function A6(e,a){tn.m(e,a);var t=Wl;if(t&&e){var n=a&&typeof a.as=="string"?a.as:"script",i='link[rel="modulepreload"][as="'+st(n)+'"][href="'+st(e)+'"]',r=i;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":r=ai(e)}if(!mt.has(r)&&(e=Z({rel:"modulepreload",href:e},a),mt.set(r,e),t.querySelector(i)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(t.querySelector(ns(r)))return}n=t.createElement("link"),ja(n,"link",e),Ma(n),t.head.appendChild(n)}}}function j6(e,a,t){tn.S(e,a,t);var n=Wl;if(n&&e){var i=gl(n).hoistableStyles,r=ei(e);a=a||"default";var m=i.get(r);if(!m){var S={loading:0,preload:null};if(m=n.querySelector(ts(r)))S.loading=5;else{e=Z({rel:"stylesheet",href:e,"data-precedence":a},t),(t=mt.get(r))&&a1(e,t);var A=m=n.createElement("link");Ma(A),ja(A,"link",e),A._p=new Promise(function(V,K){A.onload=V,A.onerror=K}),A.addEventListener("load",function(){S.loading|=1}),A.addEventListener("error",function(){S.loading|=2}),S.loading|=4,qr(m,a,n)}m={type:"stylesheet",instance:m,count:1,state:S},i.set(r,m)}}}function N6(e,a){tn.X(e,a);var t=Wl;if(t&&e){var n=gl(t).hoistableScripts,i=ai(e),r=n.get(i);r||(r=t.querySelector(ns(i)),r||(e=Z({src:e,async:!0},a),(a=mt.get(i))&&t1(e,a),r=t.createElement("script"),Ma(r),ja(r,"link",e),t.head.appendChild(r)),r={type:"script",instance:r,count:1,state:null},n.set(i,r))}}function O6(e,a){tn.M(e,a);var t=Wl;if(t&&e){var n=gl(t).hoistableScripts,i=ai(e),r=n.get(i);r||(r=t.querySelector(ns(i)),r||(e=Z({src:e,async:!0,type:"module"},a),(a=mt.get(i))&&t1(e,a),r=t.createElement("script"),Ma(r),ja(r,"link",e),t.head.appendChild(r)),r={type:"script",instance:r,count:1,state:null},n.set(i,r))}}function Ch(e,a,t,n){var i=(i=H.current)?as(i):null;if(!i)throw Error(c(446));switch(e){case"meta":case"title":return null;case"style":return typeof t.precedence=="string"&&typeof t.href=="string"?(t=ei(t.href),a=gl(i).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(t.rel==="stylesheet"&&typeof t.href=="string"&&typeof t.precedence=="string"){e=ei(t.href);var r=gl(i).hoistableStyles,m=r.get(e);if(m||(i=i.ownerDocument||i,m={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},r.set(e,m),(r=i.querySelector(ts(e)))?r._p||(m.instance=r,m.state.loading=5):(r=mt.get(e),r||(r={rel:"preload",as:"style",href:t.href,crossOrigin:t.crossOrigin,integrity:t.integrity,media:t.media,hrefLang:t.hrefLang,referrerPolicy:t.referrerPolicy},mt.set(e,r)),R6(i,e,r,m.state))),a&&n===null)throw Error(c(528,""));return m}if(a&&n!==null)throw Error(c(529,""));return null;case"script":return a=t.async,t=t.src,typeof t=="string"&&a&&typeof a!="function"&&typeof a!="symbol"?(t=ai(t),a=gl(i).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(c(444,e))}}function ei(e){return'href="'+st(e)+'"'}function ts(e){return'link[rel="stylesheet"]['+e+"]"}function Eh(e){return Z({},e,{"data-precedence":e.precedence,precedence:null})}function R6(e,a,t,n){if(a=e.querySelector('link[rel="preload"][as="style"]['+a+"]")){if(a[js]!==!0){n.loading=1;return}}else a=e.createElement("link"),a[js]=!0,a.onload=a.onerror=H0.bind(null,a),ja(a,"link",t),Ma(a),e.head.appendChild(a);n.preload=a,a.addEventListener("load",function(){return n.loading|=1}),a.addEventListener("error",function(){return n.loading|=2})}function ai(e){return'[src="'+st(e)+'"]'}function ns(e){return"script[async]"+e}function Th(e,a,t){if(a.count++,a.instance===null)switch(a.type){case"style":var n=e.querySelector('style[data-href~="'+st(t.href)+'"]');if(n)return a.instance=n,Ma(n),n;var i=Z({},t,{"data-href":t.href,"data-precedence":t.precedence,href:null,precedence:null});return n=(e.ownerDocument||e).createElement("style"),Ma(n),ja(n,"style",i),qr(n,t.precedence,e),a.instance=n;case"stylesheet":i=ei(t.href);var r=e.querySelector(ts(i));if(r)return a.state.loading|=4,a.instance=r,Ma(r),r;n=Eh(t),(i=mt.get(i))&&a1(n,i),r=(e.ownerDocument||e).createElement("link"),Ma(r);var m=r;return m._p=new Promise(function(S,A){m.onload=S,m.onerror=A}),ja(r,"link",n),a.state.loading|=4,qr(r,t.precedence,e),a.instance=r;case"script":return r=ai(t.src),(i=e.querySelector(ns(r)))?(a.instance=i,Ma(i),i):(n=t,(i=mt.get(r))&&(n=Z({},t),t1(n,i)),e=e.ownerDocument||e,i=e.createElement("script"),Ma(i),ja(i,"link",n),e.head.appendChild(i),a.instance=i);case"void":return null;default:throw Error(c(443,a.type))}else a.type==="stylesheet"&&(a.state.loading&4)===0&&(n=a.instance,a.state.loading|=4,qr(n,t.precedence,e));return a.instance}function qr(e,a,t){for(var n=t.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),i=n.length?n[n.length-1]:null,r=i,m=0;m<n.length;m++){var S=n[m];if(S.dataset.precedence===a)r=S;else if(r!==i)break}r?r.parentNode.insertBefore(e,r.nextSibling):(a=t.nodeType===9?t.head:t,a.insertBefore(e,a.firstChild))}function a1(e,a){e.crossOrigin==null&&(e.crossOrigin=a.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=a.referrerPolicy),e.title==null&&(e.title=a.title)}function t1(e,a){e.crossOrigin==null&&(e.crossOrigin=a.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=a.referrerPolicy),e.integrity==null&&(e.integrity=a.integrity)}var Gr=null;function kh(e,a,t){if(Gr===null){var n=new Map,i=Gr=new Map;i.set(t,n)}else i=Gr,n=i.get(t),n||(n=new Map,i.set(t,n));if(n.has(e))return n;for(n.set(e,null),t=t.getElementsByTagName(e),i=0;i<t.length;i++){var r=t[i];if(!(r[gi]||r[Ca]||e==="link"&&r.getAttribute("rel")==="stylesheet")&&r.namespaceURI!=="http://www.w3.org/2000/svg"){var m=r.getAttribute(a)||"";m=e+m;var S=n.get(m);S?S.push(r):n.set(m,[r])}}return n}function n1(e,a,t){e=e.ownerDocument||e,e.head.insertBefore(t,a==="title"?e.querySelector("head > title"):null)}function L6(e,a,t){if(t===1||a.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof a.precedence!="string"||typeof a.href!="string"||a.href==="")break;return!0;case"link":if(typeof a.rel!="string"||typeof a.href!="string"||a.href===""||a.onLoad||a.onError)break;switch(a.rel){case"stylesheet":return e=a.disabled,typeof a.precedence=="string"&&e==null;default:return!0}case"script":if(a.async&&typeof a.async!="function"&&typeof a.async!="symbol"&&!a.onLoad&&!a.onError&&a.src&&typeof a.src=="string")return!0}return!1}function Ah(e,a){return e==="img"&&a.src!=null&&a.src!==""&&a.onLoad==null&&a.loading!=="lazy"}function jh(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Nh(e){return(e.width||100)*(e.height||100)*(typeof devicePixelRatio=="number"?devicePixelRatio:1)*.25}function Oh(e,a){typeof a.decode=="function"&&(e.imgCount++,a.complete||(e.imgBytes+=Nh(a),e.suspenseyImages.push(a)),e=_6.bind(e),a.decode().then(e,e))}function D6(e,a,t,n){if(t.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(t.state.loading&4)===0){if(t.instance===null){var i=ei(n.href),r=a.querySelector(ts(i));if(r){a=r._p,a!==null&&typeof a=="object"&&typeof a.then=="function"&&(e.count++,e=ls.bind(e),a.then(e,e)),t.state.loading|=4,t.instance=r,Ma(r);return}r=a.ownerDocument||a,n=Eh(n),(i=mt.get(i))&&a1(n,i),r=r.createElement("link"),Ma(r);var m=r;m._p=new Promise(function(S,A){m.onload=S,m.onerror=A}),ja(r,"link",n),t.instance=r}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(t,a),(a=t.state.preload)&&(t.state.loading&3)===0&&(e.count++,t=ls.bind(e),a.addEventListener("load",t),a.addEventListener("error",t))}}var Yr=0;function H6(e,a){return e.stylesheets&&e.count===0&&Xr(e,e.stylesheets),0<e.count||0<e.imgCount?function(t){var n=setTimeout(function(){if(e.stylesheets&&Xr(e,e.stylesheets),e.unsuspend){var r=e.unsuspend;e.unsuspend=null,r()}},6e4+a);0<e.imgBytes&&Yr===0&&(Yr=62500*e6());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Xr(e,e.stylesheets),e.unsuspend)){var r=e.unsuspend;e.unsuspend=null,r()}},(e.imgBytes>Yr?50:800)+a);return e.unsuspend=t,function(){e.unsuspend=null,clearTimeout(n),clearTimeout(i)}}:null}function Rh(e){if(e.count===0&&(e.imgCount===0||!e.waitingForImages)){if(e.stylesheets)Xr(e,e.stylesheets);else if(e.unsuspend){var a=e.unsuspend;e.unsuspend=null,a()}}}function ls(){this.count--,Rh(this)}function _6(){this.imgCount--,Rh(this)}var $r=null;function Xr(e,a){e.stylesheets=null,e.unsuspend!==null&&(e.count++,$r=new Map,a.forEach(U6,e),$r=null,ls.call(e))}function U6(e,a){if(!(a.state.loading&4)){var t=$r.get(e);if(t)var n=t.get(null);else{t=new Map,$r.set(e,t);for(var i=e.querySelectorAll("link[data-precedence],style[data-precedence]"),r=0;r<i.length;r++){var m=i[r];(m.nodeName==="LINK"||m.getAttribute("media")!=="not all")&&(t.set(m.dataset.precedence,m),n=m)}n&&t.set(null,n)}i=a.instance,m=i.getAttribute("data-precedence"),r=t.get(m)||n,r===n&&t.set(null,i),t.set(m,i),this.count++,n=ls.bind(this),i.addEventListener("load",n),i.addEventListener("error",n),r?r.parentNode.insertBefore(i,r.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),a.state.loading|=4}}var ti={$$typeof:D,Provider:null,Consumer:null,_currentValue:Ha,_currentValue2:Ha,_threadCount:0};function B6(e,a,t,n,i,r,m,S,A){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Hu(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Hu(0),this.hiddenUpdates=Hu(null),this.identifierPrefix=n,this.onUncaughtError=i,this.onCaughtError=r,this.onRecoverableError=m,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=A,this.transitionTypes=null,this.incompleteTransitions=new Map}function Lh(e,a,t,n,i,r,m,S,A,V,K,ee){return e=new B6(e,a,t,m,A,V,K,ee,S),a=1,r===!0&&(a|=24),r=Ya(3,null,null,a),e.current=r,r.stateNode=e,a=yc(),a.refCount++,e.pooledCache=a,a.refCount++,r.memoizedState={element:n,isDehydrated:t,cache:a},wc(r),e}function Dh(e){return e?(e=kl,e):kl}function Hh(e,a,t,n,i,r){i=Dh(i),n.context===null?n.context=i:n.pendingContext=i,n=mn(a),n.payload={element:t},r=r===void 0?null:r,r!==null&&(n.callback=r),t=vn(e,n,a),t!==null&&(Ia(t,e,a),Di(t,e,a))}function _h(e,a){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var t=e.retryLane;e.retryLane=t!==0&&t<a?t:a}}function l1(e,a){_h(e,a),(e=e.alternate)&&_h(e,a)}function Uh(e){if(e.tag===13||e.tag===31){var a=$n(e,67108864);a!==null&&Ia(a,e,67108864),l1(e,67108864)}}function Bh(e){if(e.tag===13||e.tag===31){var a=nt();a=_u(a);var t=$n(e,a);t!==null&&Ia(t,e,a),l1(e,a)}}var ni=!0;function V6(e,a,t,n){var i=ge.T;ge.T=null;var r=Te.p;try{Te.p=2,i1(e,a,t,n)}finally{Te.p=r,ge.T=i}}function q6(e,a,t,n){var i=ge.T;ge.T=null;var r=Te.p;try{Te.p=8,i1(e,a,t,n)}finally{Te.p=r,ge.T=i}}function i1(e,a,t,n){if(ni){var i=s1(n);if(i===null)Vo(e,a,n,Kr,t),qh(e,n);else if(Y6(i,e,a,t,n))n.stopPropagation();else if(qh(e,n),a&4&&-1<G6.indexOf(e)){for(;i!==null;){var r=yl(i);if(r!==null)switch(r.tag){case 3:if(r=r.stateNode,r.current.memoizedState.isDehydrated){var m=Bn(r.pendingLanes);if(m!==0){var S=r;for(S.pendingLanes|=2,S.entangledLanes|=2;m;){var A=1<<31-Qa(m);S.entanglements[1]|=A,m&=~A}Rt(r),(Xe&6)===0&&(Nr=Za()+500,Ji(0))}}break;case 31:case 13:S=$n(r,2),S!==null&&Ia(S,r,2),Lr(),l1(r,2)}if(r=s1(n),r===null&&Vo(e,a,n,Kr,t),r===i)break;i=r}i!==null&&n.stopPropagation()}else Vo(e,a,n,null,t)}}function s1(e){return e=$u(e),r1(e)}var Kr=null;function r1(e){if(Kr=null,e=Vn(e),e!==null){var a=o(e);if(a===null)e=null;else{var t=a.tag;if(t===13){if(e=d(a),e!==null)return e;e=null}else if(t===31){if(e=p(a),e!==null)return e;e=null}else if(t===3){if(a.stateNode.current.memoizedState.isDehydrated)return a.tag===3?a.stateNode.containerInfo:null;e=null}else a!==e&&(e=null)}}return Kr=e,null}function Vh(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"fullscreenerror":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"resize":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(e3()){case x0:return 2;case C0:return 8;case Cs:case a3:return 32;case E0:return 268435456;default:return 32}default:return 32}}var u1=!1,Tn=null,kn=null,An=null,is=new Map,ss=new Map,jn=[],G6="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function qh(e,a){switch(e){case"focusin":case"focusout":Tn=null;break;case"dragenter":case"dragleave":kn=null;break;case"mouseover":case"mouseout":An=null;break;case"pointerover":case"pointerout":is.delete(a.pointerId);break;case"gotpointercapture":case"lostpointercapture":ss.delete(a.pointerId)}}function rs(e,a,t,n,i,r){return e===null||e.nativeEvent!==r?(e={blockedOn:a,domEventName:t,eventSystemFlags:n,nativeEvent:r,targetContainers:[i]},a!==null&&(a=yl(a),a!==null&&Uh(a)),e):(e.eventSystemFlags|=n,a=e.targetContainers,i!==null&&a.indexOf(i)===-1&&a.push(i),e)}function Y6(e,a,t,n,i){switch(a){case"focusin":return Tn=rs(Tn,e,a,t,n,i),!0;case"dragenter":return kn=rs(kn,e,a,t,n,i),!0;case"mouseover":return An=rs(An,e,a,t,n,i),!0;case"pointerover":var r=i.pointerId;return is.set(r,rs(is.get(r)||null,e,a,t,n,i)),!0;case"gotpointercapture":return r=i.pointerId,ss.set(r,rs(ss.get(r)||null,e,a,t,n,i)),!0}return!1}function Gh(e){var a=Vn(e.target);if(a!==null){var t=o(a);if(t!==null){if(a=t.tag,a===13){if(a=d(t),a!==null){e.blockedOn=a,R0(e.priority,function(){Bh(t)});return}}else if(a===31){if(a=p(t),a!==null){e.blockedOn=a,R0(e.priority,function(){Bh(t)});return}}else if(a===3&&t.stateNode.current.memoizedState.isDehydrated){e.blockedOn=t.tag===3?t.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Ir(e){if(e.blockedOn!==null)return!1;for(var a=e.targetContainers;0<a.length;){var t=s1(e.nativeEvent);if(t===null){t=e.nativeEvent;var n=new t.constructor(t.type,t);Yu=n,t.target.dispatchEvent(n),Yu=null}else return a=yl(t),a!==null&&Uh(a),e.blockedOn=t,!1;a.shift()}return!0}function Yh(e,a,t){Ir(e)&&t.delete(a)}function $6(){u1=!1,Tn!==null&&Ir(Tn)&&(Tn=null),kn!==null&&Ir(kn)&&(kn=null),An!==null&&Ir(An)&&(An=null),is.forEach(Yh),ss.forEach(Yh)}function Zr(e,a){e.blockedOn===a&&(e.blockedOn=null,u1||(u1=!0,l.unstable_scheduleCallback(l.unstable_NormalPriority,$6)))}var Fr=null;function $h(e){Fr!==e&&(Fr=e,l.unstable_scheduleCallback(l.unstable_NormalPriority,function(){Fr===e&&(Fr=null);for(var a=0;a<e.length;a+=3){var t=e[a],n=e[a+1],i=e[a+2];if(typeof n!="function"){if(r1(n||t)===null)continue;break}var r=yl(t);r!==null&&(e.splice(a,3),a-=3,Gc(r,{pending:!0,data:i,method:t.method,action:n},n,i))}}))}function li(e){function a(A){return Zr(A,e)}Tn!==null&&Zr(Tn,e),kn!==null&&Zr(kn,e),An!==null&&Zr(An,e),is.forEach(a),ss.forEach(a);for(var t=0;t<jn.length;t++){var n=jn[t];n.blockedOn===e&&(n.blockedOn=null)}for(;0<jn.length&&(t=jn[0],t.blockedOn===null);)Gh(t),t.blockedOn===null&&jn.shift();if(t=(e.ownerDocument||e).$$reactFormReplay,t!=null)for(n=0;n<t.length;n+=3){var i=t[n],r=t[n+1],m=i[Ga]||null;if(typeof r=="function")m||$h(t);else if(m){var S=null;if(r&&r.hasAttribute("formAction")){if(i=r,m=r[Ga]||null)S=m.formAction;else if(r1(i)!==null)continue}else S=m.action;typeof S=="function"?t[n+1]=S:(t.splice(n,3),n-=3),$h(t)}}}function Xh(){function e(r){r.canIntercept&&r.info==="react-transition"&&r.intercept({handler:function(){return new Promise(function(m){return i=m})},focusReset:"manual",scroll:"manual"})}function a(){i!==null&&(i(),i=null),n||setTimeout(t,20)}function t(){if(!n&&!navigation.transition){var r=navigation.currentEntry;r&&r.url!=null&&navigation.navigate(r.url,{state:r.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var n=!1,i=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",a),navigation.addEventListener("navigateerror",a),setTimeout(t,100),function(){n=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",a),navigation.removeEventListener("navigateerror",a),i!==null&&(i(),i=null)}}}function c1(e){this._internalRoot=e}Qr.prototype.render=c1.prototype.render=function(e){var a=this._internalRoot;if(a===null)throw Error(c(409));var t=a.current,n=nt();Hh(t,n,e,a,null,null)},Qr.prototype.unmount=c1.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var a=e.containerInfo;Hh(e.current,2,null,e,null,null),Lr(),a[pl]=null}};function Qr(e){this._internalRoot=e}Qr.prototype.unstable_scheduleHydration=function(e){if(e){var a=O0();e={blockedOn:null,target:e,priority:a};for(var t=0;t<jn.length&&a!==0&&a<jn[t].priority;t++);jn.splice(t,0,e),t===0&&Gh(e)}};var Kh=s.version;if(Kh!=="19.3.0")throw Error(c(527,Kh,"19.3.0"));Te.findDOMNode=function(e){var a=e._reactInternals;if(a===void 0)throw typeof e.render=="function"?Error(c(188)):(e=Object.keys(e).join(","),Error(c(268,e)));return e=g(a),e=e!==null?v(e):null,e=e===null?null:e.stateNode,e};var X6={bundleType:0,version:"19.3.0",rendererPackageName:"react-dom",currentDispatcherRef:ge,reconcilerVersion:"19.3.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Jr=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Jr.isDisabled&&Jr.supportsFiber)try{vi=Jr.inject(X6),Fa=Jr}catch{}}return cs.createRoot=function(e,a){if(!f(e))throw Error(c(299));var t=!1,n="",i=Df,r=Hf,m=_f;return a!=null&&(a.unstable_strictMode===!0&&(t=!0),a.identifierPrefix!==void 0&&(n=a.identifierPrefix),a.onUncaughtError!==void 0&&(i=a.onUncaughtError),a.onCaughtError!==void 0&&(r=a.onCaughtError),a.onRecoverableError!==void 0&&(m=a.onRecoverableError)),a=Lh(e,1,!1,null,null,t,n,null,i,r,m,Xh),e[pl]=a.current,Bo(e),new c1(a)},cs.hydrateRoot=function(e,a,t){if(!f(e))throw Error(c(299));var n=!1,i="",r=Df,m=Hf,S=_f,A=null;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(i=t.identifierPrefix),t.onUncaughtError!==void 0&&(r=t.onUncaughtError),t.onCaughtError!==void 0&&(m=t.onCaughtError),t.onRecoverableError!==void 0&&(S=t.onRecoverableError),t.formState!==void 0&&(A=t.formState)),a=Lh(e,1,!0,a,t??null,n,i,A,r,m,S,Xh),a.context=Dh(null),t=a.current,n=nt(),n=_u(n),i=mn(n),i.callback=null,vn(t,i,n),t=n,a.current.lanes=t,yi(a,t),Rt(a),e[pl]=a.current,Bo(e),new Qr(a)},cs.version="19.3.0",cs}var im;function ob(){if(im)return d1.exports;im=1;function l(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(l)}catch(s){console.error(s)}}return l(),d1.exports=cb(),d1.exports}var fb=ob(),w=W1();function ru(l,s){return`kit:${l}:${s}`}function p5(l){return new TextEncoder().encode(l).length}function sm(l,s,u){try{const c=window.localStorage.getItem(ru(l,s));return c==null?void 0:u(JSON.parse(c))}catch{return}}function rm(l,s,u,c=Number.POSITIVE_INFINITY){let f;try{f=JSON.stringify(u)}catch{return"unavailable"}if(p5(f)>c)return"tooLarge";try{return window.localStorage.setItem(ru(l,s),f),"stored"}catch{return"unavailable"}}function db(l,s,u){const c=w.useRef(u);c.current=u;const f=ru(l,s),[o,d]=w.useState(()=>({key:f,value:sm(l,s,u.validate)??u.initial})),p=w.useRef(o.value);let y=o.value;o.key!==f&&(y=sm(l,s,u.validate)??u.initial,p.current=y,d({key:f,value:y}));const g=w.useRef(null),v=w.useCallback(()=>{const M=g.current;M&&(window.clearTimeout(M.timer),g.current=null,rm(l,s,M.value,c.current.maxBytes))},[l,s]),b=w.useCallback(M=>{const z=typeof M=="function"?M(p.current):M;p.current=z,d({key:ru(l,s),value:z});const{delayMs:x,maxBytes:E}=c.current;if(!x)return rm(l,s,z,E);let T;try{T=JSON.stringify(z)}catch{return"unavailable"}return E!=null&&p5(T)>E?"tooLarge":(g.current&&window.clearTimeout(g.current.timer),g.current={value:z,timer:window.setTimeout(v,x)},"stored")},[v,l,s]);return w.useEffect(()=>{const M=z=>{var E,T;if(z.key!==f||z.newValue==null)return;let x;try{x=c.current.validate(JSON.parse(z.newValue))}catch{x=void 0}x!==void 0&&(p.current=x,d({key:f,value:x}),(T=(E=c.current).onExternal)==null||T.call(E,x))};return window.addEventListener("storage",M),window.addEventListener("pagehide",v),()=>{window.removeEventListener("storage",M),window.removeEventListener("pagehide",v),v()}},[v,f]),[y,b]}var hb={colorPickerSquare:"Saturation and brightness",colorPickerHue:"Hue",colorPickerHex:"Hex color",colorWheel:"color wheel",colorWheelLightness:"{label} lightness",colorWheelOffset:"{label}: {x}, {y}",curveEditor:"Curve",curveEditorPoint:"Point {index}: {x}, {y}",expandPanelGroup:"Expand panel group",collapsePanelGroup:"Collapse panel group",floatingPanelClose:"Close {title}",floatingPanelResize:"Resize",keyframeLane:"Keyframes",keyframeAt:"Keyframe at {time}",levelMeter:"Audio levels",previewDialogOk:"OK",previewDialogCancel:"Cancel",previewDialogReset:"Reset",previewDialogPreview:"Preview",previewDialogPending:"Updating the preview…",previewDialogOff:"Preview is off: {error}",transportControls:"Transport controls",closePanel:"Close Panel",maximizeFrame:"Maximize Frame",restoreWorkspace:"Restore Workspace",panelMenu:"Panel menu",moreTabs:"More tabs",resizePanels:"Resize panels",passwordShow:"Show password",passwordHide:"Hide password",close:"Close",confirm:"Confirm",cancel:"Cancel",sheet:"Side panel",noData:"No data",loading:"Loading",breadcrumb:"Breadcrumb",pagination:"Pages",paginationRange:"{first}–{last} of {total}",previousPage:"Previous page",nextPage:"Next page",pageNumber:"Page {page}",pageSize:"Rows per page",perPage:"{size} / page",formRequired:"{label} is required",formEmail:"{label} must be an email address",formUrl:"{label} must be a web address",formPattern:"{label} is not in the expected format",formMinLength:"{label} needs at least {min} characters",formMaxLength:"{label} takes at most {max} characters",formMinValue:"{label} must be at least {min}",formMaxValue:"{label} must be at most {max}",noMatches:"No matches",clear:"Clear",allChosen:"All",selectAllRows:"Select all rows on this page",selectRow:"Select row",rowActions:"Actions",selectionActions:"Selection actions",selectedCount:"{count} selected",clearSelection:"Clear selection"},mb={colorPickerSquare:"饱和度和明度",colorPickerHue:"色相",colorPickerHex:"十六进制颜色",colorWheel:"色轮",colorWheelLightness:"{label}亮度",colorWheelOffset:"{label}:{x},{y}",curveEditor:"曲线",curveEditorPoint:"点 {index}:{x},{y}",expandPanelGroup:"展开面板组",collapsePanelGroup:"折叠面板组",floatingPanelClose:"关闭{title}",floatingPanelResize:"调整大小",keyframeLane:"关键帧",keyframeAt:"{time} 处的关键帧",levelMeter:"音频电平",previewDialogOk:"确定",previewDialogCancel:"取消",previewDialogReset:"重置",previewDialogPreview:"预览",previewDialogPending:"正在更新预览…",previewDialogOff:"预览已关闭:{error}",transportControls:"播放控件",closePanel:"关闭面板",maximizeFrame:"最大化框架",restoreWorkspace:"恢复工作区",panelMenu:"面板菜单",moreTabs:"更多选项卡",resizePanels:"调整面板大小",passwordShow:"显示密码",passwordHide:"隐藏密码",close:"关闭",confirm:"确定",cancel:"取消",sheet:"侧边面板",noData:"暂无数据",loading:"加载中",breadcrumb:"面包屑导航",pagination:"分页",paginationRange:"第 {first}–{last} 条,共 {total} 条",previousPage:"上一页",nextPage:"下一页",pageNumber:"第 {page} 页",pageSize:"每页行数",perPage:"{size} 条/页",formRequired:"请填写{label}",formEmail:"{label}必须是邮箱地址",formUrl:"{label}必须是网址",formPattern:"{label}格式不正确",formMinLength:"{label}至少需要 {min} 个字符",formMaxLength:"{label}最多 {max} 个字符",formMinValue:"{label}不能小于 {min}",formMaxValue:"{label}不能大于 {max}",noMatches:"没有匹配项",clear:"清除",allChosen:"全部",selectAllRows:"选择本页所有行",selectRow:"选择行",rowActions:"操作",selectionActions:"所选项的操作",selectedCount:"已选 {count} 项",clearSelection:"取消选择"},vb={"en-US":hb,"zh-CN":mb};function pb(l,s){const u=[s,s.split("-")[0],"en-US"].map(c=>{var f;return l[c]??((f=Object.entries(l).find(([o])=>o.split("-")[0]===c))==null?void 0:f[1])}).filter(c=>!!c);return(c,f)=>{var d;const o=((d=u.find(p=>c in p))==null?void 0:d[c])??c;return f?o.replace(/\{(\w+)\}/g,(p,y)=>y in f?String(f[y]):p):o}}var yb=pb(vb,"en-US"),y5=w.createContext(null);function gb(){return w.useContext(y5)??yb}function Mb({strings:l,children:s}){return h.jsx(y5.Provider,{value:l,children:s})}var bb={hidden:!1,disabled:!1},wb={state:()=>bb,renderExtras:()=>null,drawn:()=>{}},g5=w.createContext(null);function M5(){return w.useContext(g5)??wb}function Sb({elements:l,children:s}){return h.jsx(g5.Provider,{value:l,children:s})}var zb='button[data-kit-ui-id^="command:"], button[data-kit-ui-id^="tool:"], button[data-kit-ui-id^="host:"]',xb='button:not(:disabled), input:not(:disabled), select:not(:disabled), textarea:not(:disabled), a[href], [tabindex]:not([tabindex="-1"])';function e0({open:l,anchor:s,onClose:u,label:c,className:f="",testId:o,children:d}){const p=w.useRef(null),[y,g]=w.useState(null),v=w.useRef(u);v.current=u,w.useLayoutEffect(()=>{if(!l){g(null);return}const M=()=>{var C,N;const x=(C=s.current)==null?void 0:C.getBoundingClientRect();if(!x)return;const E=((N=p.current)==null?void 0:N.offsetWidth)??0,T=x.bottom+4;g({left:Math.max(4,Math.min(x.left,window.innerWidth-E-4)),top:T,maxHeight:Math.max(0,window.innerHeight-T-8)})};M(),window.addEventListener("resize",M);const z=typeof ResizeObserver=="function"&&p.current?new ResizeObserver(M):null;return z&&p.current&&z.observe(p.current),()=>{window.removeEventListener("resize",M),z==null||z.disconnect()}},[s,l]),w.useLayoutEffect(()=>{var x;if(!l)return;const M=(x=s.current)==null?void 0:x.querySelector("button"),z=p.current;return()=>{const E=document.activeElement;M!=null&&M.isConnected&&(!E||E===document.body||!E.isConnected||z!=null&&z.contains(E))&&M.focus({preventScroll:!0})}},[s,l]);const b=y!==null;return w.useLayoutEffect(()=>{const M=p.current;!l||!b||!M||M.contains(document.activeElement)||(M.querySelector(xb)??M).focus({preventScroll:!0})},[l,b]),w.useEffect(()=>{if(!l)return;const M=x=>{var E;(E=s.current)!=null&&E.contains(x.target)||v.current()},z=x=>{x.key==="Escape"&&!x.defaultPrevented&&v.current()};return window.addEventListener("pointerdown",M,!0),window.addEventListener("keydown",z),()=>{window.removeEventListener("pointerdown",M,!0),window.removeEventListener("keydown",z)}},[s,l]),l?h.jsx("div",{ref:p,className:`kui-popover kui-drop-panel ${f}`,role:"dialog","aria-label":c,tabIndex:-1,"data-testid":o,style:y?{left:y.left,top:y.top,maxHeight:y.maxHeight}:{visibility:"hidden"},onClick:M=>{M.target.closest(zb)&&u()},children:d}):null}var um=.25,cm=24,b5=1.5;function Cb({size:l=cm,strokeWidth:s=b5,absoluteStrokeWidth:u=!1}={}){return u?s*cm/l:s}var Eb=Object.defineProperty,Tb=(l,s)=>{for(var u in s)Eb(l,u,{get:s[u],enumerable:!0})},kb={};Tb(kb,{AArrowDown:()=>Ab,AArrowUp:()=>jb,ALargeSmall:()=>Nb,Accessibility:()=>Ob,Activity:()=>w5,AlarmClock:()=>Rb,AlignCenterHorizontal:()=>S5,AlignCenterVertical:()=>Lb,AlignEndHorizontal:()=>Db,AlignEndVertical:()=>Hb,AlignHorizontalJustifyCenter:()=>_b,AlignStartHorizontal:()=>Ub,AlignStartVertical:()=>Bb,AlignVerticalJustifyCenter:()=>Vb,AlignVerticalJustifyEnd:()=>qb,AlignVerticalJustifyStart:()=>Gb,AnimationAppear:()=>Yb,AnimationFade:()=>$b,AnimationFadeOut:()=>Xb,AnimationFloatIn:()=>Kb,AnimationFlyIn:()=>Ib,AnimationFlyOut:()=>Zb,AnimationGrowShrink:()=>Fb,AnimationPath:()=>Qb,AnimationPulse:()=>Jb,AnimationSpin:()=>Pb,AnimationSplit:()=>Wb,AnimationWipe:()=>e8,AnimationZoom:()=>a8,Aperture:()=>t8,AppWindow:()=>n8,AppWindowMac:()=>l8,Arc:()=>i8,ArrayPath:()=>s8,ArrayPolar:()=>r8,ArrayRectangular:()=>u8,ArrowDown:()=>z5,ArrowDownAZ:()=>c8,ArrowDownToLine:()=>x5,ArrowDownWideNarrow:()=>o8,ArrowLeft:()=>C5,ArrowLeftFromLine:()=>f8,ArrowLeftRight:()=>E5,ArrowLeftToLine:()=>T5,ArrowRight:()=>k5,ArrowRightFromLine:()=>d8,ArrowRightLeft:()=>A5,ArrowRightToLine:()=>j5,ArrowUp:()=>N5,ArrowUpDown:()=>O5,ArrowUpRight:()=>h8,AtSign:()=>m8,AudioLines:()=>v8,AudioWaveform:()=>p8,Ban:()=>y8,Bandage:()=>g8,Baseline:()=>M8,Bell:()=>R5,BetweenHorizontalEnd:()=>b8,BetweenHorizontalStart:()=>w8,BetweenVerticalEnd:()=>S8,BetweenVerticalStart:()=>z8,Blend:()=>L5,Blocks:()=>x8,Bold:()=>D5,BookBookmark:()=>C8,BookOpen:()=>H5,BookOpenText:()=>E8,Bookmark:()=>_5,Bot:()=>T8,Box:()=>U5,Boxes:()=>k8,Braces:()=>B5,BreakLine:()=>A8,Briefcase:()=>j8,BriefcaseBusiness:()=>N8,BringToFront:()=>V5,Brush:()=>q5,BrushCleaning:()=>O8,Cable:()=>R8,Calendar:()=>G5,CalendarClock:()=>L8,CalendarDays:()=>D8,CalendarRange:()=>H8,Camera:()=>Y5,Captions:()=>_8,CaseLower:()=>U8,CaseSensitive:()=>B8,CaseUpper:()=>V8,CenterLine:()=>q8,CenterMark:()=>G8,Chamfer:()=>Y8,ChartArea:()=>$8,ChartColumn:()=>$5,ChartColumnStacked:()=>X8,ChartGantt:()=>K8,ChartLine:()=>I8,ChartNoAxesColumn:()=>Z8,ChartNoAxesCombined:()=>F8,ChartPie:()=>Q8,ChartScatter:()=>J8,ChartSpline:()=>P8,Check:()=>X5,ChevronDown:()=>K5,ChevronFirst:()=>W8,ChevronLast:()=>e7,ChevronLeft:()=>I5,ChevronRight:()=>Z5,ChevronUp:()=>a7,ChevronsDownUp:()=>F5,ChevronsLeft:()=>Q5,ChevronsRight:()=>J5,ChevronsRightLeft:()=>t7,ChevronsUpDown:()=>P5,Circle:()=>W5,CircleAlert:()=>n7,CircleCenterRadius:()=>l7,CircleCheck:()=>i7,CircleDashed:()=>s7,CircleDot:()=>r7,CircleQuestionMark:()=>ev,CircleUserRound:()=>u7,CircleX:()=>c7,Clapperboard:()=>av,ClipExtract:()=>tv,ClipInsert:()=>o7,ClipLift:()=>nv,ClipOverwrite:()=>f7,Clipboard:()=>lv,ClipboardCheck:()=>d7,ClipboardList:()=>h7,ClipboardPaste:()=>iv,Clock:()=>sv,Clock3:()=>m7,Cloud:()=>v7,CloudDownload:()=>p7,CloudOff:()=>y7,CloudUpload:()=>g7,Cloudy:()=>M7,Code:()=>rv,CodeXml:()=>uv,Columns2:()=>cv,Columns3:()=>b7,Combine:()=>w7,Command:()=>S7,CommandGeneric:()=>ov,Compass:()=>z7,Component:()=>fv,ConstraintCoincident:()=>x7,ConstraintCollinear:()=>C7,ConstraintConcentric:()=>E7,ConstraintEqual:()=>T7,ConstraintFix:()=>k7,ConstraintHorizontal:()=>A7,ConstraintParallel:()=>j7,ConstraintPerpendicular:()=>N7,ConstraintSymmetric:()=>O7,ConstraintTangent:()=>R7,ConstraintVertical:()=>L7,ConstructionLine:()=>D7,Contact:()=>H7,Contrast:()=>dv,Cookie:()=>_7,Copy:()=>hv,CopyCheck:()=>U7,CopyPlus:()=>mv,CornerDownRight:()=>vv,CornerUpRight:()=>B7,Cpu:()=>V7,CreditCard:()=>q7,Crop:()=>pv,Crosshair:()=>yv,DashDashed:()=>G7,DashDotted:()=>Y7,DashSolid:()=>$7,Database:()=>gv,DecimalsArrowLeft:()=>X7,DecimalsArrowRight:()=>K7,Delete:()=>I7,Diameter:()=>Mv,Diamond:()=>bv,DimensionAligned:()=>Z7,DimensionAngular:()=>F7,DimensionArcLength:()=>Q7,DimensionBaseline:()=>J7,DimensionContinue:()=>P7,DimensionDiameter:()=>W7,DimensionLinear:()=>ew,DimensionOrdinate:()=>aw,DimensionRadius:()=>tw,Disc:()=>wv,DollarSign:()=>nw,Donut:()=>lw,Download:()=>Sv,Droplet:()=>iw,Droplets:()=>sw,Earth:()=>rw,Ellipse:()=>uw,Ellipsis:()=>zv,EllipsisVertical:()=>cw,Eraser:()=>xv,Expand:()=>ow,Explode:()=>fw,Extend:()=>dw,ExternalLink:()=>hw,Eye:()=>Cv,EyeOff:()=>Ev,FaceSlightlySmiling:()=>mw,FastForward:()=>Tv,Feather:()=>kv,File:()=>Av,FileArchive:()=>vw,FileCheckCorner:()=>pw,FileClock:()=>yw,FileCode:()=>jv,FileCodeCorner:()=>gw,FileDiff:()=>Mw,FileDigit:()=>bw,FileExclamationPoint:()=>ww,FileImage:()=>Sw,FileInput:()=>Nv,FileOutput:()=>Ov,FilePenLine:()=>zw,FilePlus:()=>Rv,FilePlusCorner:()=>Lv,FileSpreadsheet:()=>xw,FileSymlink:()=>Cw,FileText:()=>Ew,FileTypeCorner:()=>Tw,FileUp:()=>kw,FileVideoCamera:()=>Aw,Files:()=>jw,Fillet:()=>Nw,Film:()=>Dv,Flag:()=>Hv,Flame:()=>Ow,FlaskConical:()=>Rw,FlipHorizontal:()=>_v,Flower:()=>Lw,Focus:()=>Uv,FoldHorizontal:()=>Dw,Folder:()=>Bv,FolderCheck:()=>Hw,FolderInput:()=>_w,FolderLock:()=>Uw,FolderOpen:()=>Vv,FolderPlus:()=>Bw,FolderUp:()=>Vw,Frame:()=>qv,Fullscreen:()=>qw,Funnel:()=>Gv,GalleryHorizontalEnd:()=>Gw,Gauge:()=>Yv,Gem:()=>$v,Gift:()=>Yw,GitBranch:()=>$w,GitBranchPlus:()=>Xw,GitCompare:()=>Kw,Glasses:()=>Iw,Globe:()=>Zw,GoToIn:()=>Fw,GoToOut:()=>Qw,GraduationCap:()=>Jw,Grid2x2:()=>Xv,Grid3x2:()=>Pw,Grid3x3:()=>Kv,GripHorizontal:()=>Ww,GripVertical:()=>e9,Group:()=>Iv,Hand:()=>Zv,HardDrive:()=>a9,Hash:()=>Fv,Hatch:()=>t9,Heading:()=>Qv,Heart:()=>n9,Helix:()=>l9,Hexagon:()=>i9,Highlighter:()=>Jv,Hourglass:()=>s9,Image:()=>Pv,ImageDown:()=>r9,ImagePlus:()=>Wv,ImageUp:()=>u9,Images:()=>c9,Inbox:()=>o9,Info:()=>ep,Italic:()=>ap,KeyRound:()=>f9,Keyboard:()=>d9,Keyframe:()=>h9,KeyframeNext:()=>m9,KeyframeOn:()=>v9,KeyframePrevious:()=>p9,Lamp:()=>y9,Languages:()=>tp,Laptop:()=>g9,Lasso:()=>np,LassoSelect:()=>M9,Layers:()=>lp,Layers2:()=>b9,LayersPlus:()=>w9,LayoutDashboard:()=>S9,LayoutGrid:()=>z9,LayoutPanelLeft:()=>x9,LayoutTemplate:()=>ip,Leader:()=>C9,Lengthen:()=>E9,Library:()=>T9,LifeBuoy:()=>sp,Ligature:()=>k9,Lightbulb:()=>rp,LineSegment:()=>A9,Linetype:()=>j9,Lineweight:()=>N9,Link:()=>up,Link2:()=>cp,List:()=>op,ListChecks:()=>O9,ListFilter:()=>R9,ListIndentDecrease:()=>L9,ListIndentIncrease:()=>D9,ListOrdered:()=>fp,ListPlus:()=>H9,ListRestart:()=>_9,ListTodo:()=>U9,ListTree:()=>dp,ListVideo:()=>B9,LoaderCircle:()=>hp,Lock:()=>mp,LockKeyhole:()=>V9,LockOpen:()=>vp,LogOut:()=>q9,Lollipop:()=>G9,Magnet:()=>pp,Mail:()=>yp,MailWarning:()=>Y9,MapPin:()=>$9,MarkIn:()=>X9,MarkOut:()=>K9,Maximize:()=>I9,Maximize2:()=>Z9,Megaphone:()=>F9,Menu:()=>gp,Merge:()=>Mp,MessageSquare:()=>bp,MessageSquareDashed:()=>Q9,MessageSquarePlus:()=>J9,MessageSquareText:()=>P9,Minimize2:()=>wp,Minus:()=>Sp,Monitor:()=>W9,MonitorCog:()=>eS,MonitorPlay:()=>aS,MonitorSmartphone:()=>tS,Moon:()=>nS,Mountain:()=>lS,MountainSnow:()=>iS,MousePointer:()=>zp,MousePointer2:()=>xp,MousePointerClick:()=>Cp,Move:()=>Ep,Move3d:()=>Tp,MoveHorizontal:()=>kp,MoveRight:()=>sS,MoveUpRight:()=>Ap,MoveVertical:()=>rS,Multiline:()=>uS,Music:()=>jp,Navigation:()=>cS,Network:()=>Np,NotebookPen:()=>oS,NotebookText:()=>fS,Offset:()=>dS,Omega:()=>Op,Orbit:()=>hS,OrthoMode:()=>mS,Package:()=>Rp,PaintBucket:()=>Lp,Paintbrush:()=>Dp,Palette:()=>Hp,PanelBottom:()=>_p,PanelLeft:()=>vS,PanelLeftClose:()=>pS,PanelLeftOpen:()=>yS,PanelRight:()=>gS,PanelTop:()=>Up,PanelsTopLeft:()=>MS,Paperclip:()=>bS,Parallelogram:()=>Bp,Pause:()=>Vp,Pen:()=>wS,PenLine:()=>qp,PenTool:()=>Gp,Pencil:()=>Yp,PencilLine:()=>$p,Pentagon:()=>SS,Percent:()=>zS,Pilcrow:()=>Xp,Pill:()=>xS,Pin:()=>CS,PinOff:()=>ES,Pipette:()=>Kp,Play:()=>Ip,Plus:()=>Zp,Pointer:()=>TS,PolarTracking:()=>kS,Polyline:()=>AS,Power:()=>jS,Presentation:()=>NS,Printer:()=>Fp,Puzzle:()=>OS,QrCode:()=>Qp,Quote:()=>RS,Radar:()=>LS,Radius:()=>Jp,Rainbow:()=>Pp,Ratio:()=>DS,Ray:()=>HS,Receipt:()=>_S,RectangleHorizontal:()=>Wp,RectangleVertical:()=>US,Redo2:()=>ey,RefreshCcw:()=>BS,RefreshCw:()=>ay,Region:()=>VS,RemoveFormatting:()=>qS,Repeat:()=>ty,Replace:()=>ny,RevisionCloud:()=>GS,Rocket:()=>YS,Rotate3d:()=>$S,RotateCcw:()=>ly,RotateCcwClock:()=>XS,RotateCw:()=>iy,Rows2:()=>KS,Rows3:()=>sy,Ruler:()=>ry,RulerDimensionLine:()=>uy,Save:()=>cy,Scale:()=>IS,Scaling:()=>oy,Scan:()=>ZS,ScanEye:()=>FS,ScanFace:()=>QS,ScanSearch:()=>JS,ScanText:()=>PS,Scissors:()=>fy,ScrollText:()=>WS,Search:()=>dy,SearchCheck:()=>ez,Send:()=>hy,SendToBack:()=>my,SeparatorHorizontal:()=>az,Settings:()=>vy,Settings2:()=>py,Shapes:()=>yy,Share2:()=>gy,Shell:()=>My,ShieldAlert:()=>tz,ShieldBan:()=>nz,ShieldCheck:()=>by,Shrink:()=>lz,Sigma:()=>wy,Signature:()=>Sy,SkipBack:()=>iz,SkipForward:()=>sz,Slash:()=>rz,Slice:()=>uz,SlidersHorizontal:()=>zy,SlidersVertical:()=>cz,Snowflake:()=>oz,Sparkle:()=>fz,Sparkles:()=>xy,SpellCheck:()=>Cy,Spline:()=>Ey,SplinePointer:()=>dz,Split:()=>Ty,Square:()=>ky,SquareCheck:()=>hz,SquareCheckBig:()=>Ay,SquareDashed:()=>jy,SquareDashedMousePointer:()=>mz,SquareDot:()=>vz,SquareFunction:()=>Ny,SquareKanban:()=>pz,SquareMinus:()=>yz,SquareMousePointer:()=>gz,SquarePlus:()=>Mz,SquareSplitHorizontal:()=>bz,SquareSplitVertical:()=>wz,SquareSquare:()=>Oy,SquareStack:()=>Sz,SquareTerminal:()=>Ry,SquareX:()=>zz,SquaresExclude:()=>xz,SquaresIntersect:()=>Cz,SquaresSubtract:()=>Ez,SquaresUnite:()=>Ly,Squircle:()=>Tz,Stamp:()=>kz,Star:()=>Dy,StepBack:()=>Az,StepForward:()=>Hy,Sticker:()=>_y,StickyNote:()=>Uy,Stretch:()=>jz,StretchHorizontal:()=>Nz,Strikethrough:()=>By,Subscript:()=>Vy,Sun:()=>qy,SunDim:()=>Gy,SunMedium:()=>Oz,SunMoon:()=>Rz,SunSnow:()=>Lz,Sunrise:()=>Dz,Superscript:()=>Yy,SwatchBook:()=>$y,Table:()=>Xy,Table2:()=>Hz,TableCellsMerge:()=>_z,TableCellsSplit:()=>Uz,TableProperties:()=>Ky,Tag:()=>Iy,Tags:()=>Bz,Target:()=>Vz,Terminal:()=>qz,TextAlignCenter:()=>Zy,TextAlignEnd:()=>Fy,TextAlignJustify:()=>Qy,TextAlignStart:()=>Jy,TextCursor:()=>Py,TextCursorInput:()=>Wy,TextJustifyCenter:()=>Gz,TextJustifyEnd:()=>Yz,TextJustifyStart:()=>$z,TextWrap:()=>Xz,Thermometer:()=>Kz,ThumbsUp:()=>Iz,Ticket:()=>Zz,Timer:()=>Fz,ToggleLeft:()=>e4,Tornado:()=>Qz,TransitionCover:()=>Jz,TransitionCurtains:()=>Pz,TransitionCut:()=>Wz,TransitionDrape:()=>ex,TransitionFade:()=>ax,TransitionFallOver:()=>tx,TransitionFlash:()=>nx,TransitionMorph:()=>lx,TransitionNone:()=>ix,TransitionPrestige:()=>sx,TransitionPush:()=>rx,TransitionRandomBars:()=>ux,TransitionReveal:()=>cx,TransitionShape:()=>ox,TransitionSplit:()=>fx,TransitionUncover:()=>dx,TransitionWind:()=>hx,TransitionWipe:()=>mx,Trash:()=>a4,TrendingUp:()=>vx,Triangle:()=>px,TriangleAlert:()=>yx,TrianglesCenterlineDashedHorizontal:()=>gx,Type:()=>t4,TypeOutline:()=>Mx,Underline:()=>n4,Undo2:()=>l4,UnfoldHorizontal:()=>bx,UnfoldVertical:()=>wx,Ungroup:()=>i4,Unlink:()=>s4,Upload:()=>r4,User:()=>Sx,UserMinus:()=>zx,UserPlus:()=>xx,UserRound:()=>Cx,Users:()=>Ex,Variable:()=>Tx,VectorPolygon:()=>u4,VectorSquare:()=>c4,Video:()=>o4,Volume2:()=>f4,WalletCards:()=>kx,WandSparkles:()=>d4,WavesHorizontal:()=>h4,Waypoints:()=>m4,Webhook:()=>Ax,WholeWord:()=>v4,Wind:()=>jx,Workflow:()=>Nx,Wrench:()=>Ox,X:()=>p4,Zap:()=>y4,ZapOff:()=>Rx,ZoomIn:()=>g4,ZoomOut:()=>Lx});var Ab={name:"a-arrow-down",family:"ui",paths:["m14 12 4 4 4-4","M18 16V7","m2 16 4.039-9.69a.5.5 0 0 1 .923 0L11 16","M3.304 13h6.392"],fills:[],accents:[]},jb={name:"a-arrow-up",family:"ui",paths:["m14 11 4-4 4 4","M18 16V7","m2 16 4.039-9.69a.5.5 0 0 1 .923 0L11 16","M3.304 13h6.392"],fills:[],accents:[]},Nb={name:"a-large-small",family:"ui",paths:["m15 16 2.536-7.328a1.02 1.02 1 0 1 1.928 0L22 16","M15.697 14h5.606","m2 16 4.039-9.69a.5.5 0 0 1 .923 0L11 16","M3.304 13h6.392"],fills:[],accents:[]},Ob={name:"accessibility",family:"ui",paths:["M15 4a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","m18 19 1-7-6 1","m5 8 3-3 5.5 3-2.36 3.5","M4.24 14.5a5 5 0 0 0 6.88 6","M13.76 17.5a5 5 0 0 0-6.88-6"],fills:[],accents:[]},w5={name:"activity",family:"ui",paths:["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"],fills:[],accents:[]},Rb={name:"alarm-clock",family:"ui",paths:["M4 13a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M12 9v4l2 2","M5 3 2 6","m22 6-3-3","M6.38 18.7 4 21","M17.64 18.67 20 21"],fills:[],accents:[]},S5={name:"align-center-horizontal",family:"ui",paths:["M2 12h20","M10 16v4a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2v-4","M10 8V4a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v4","M20 16v1a2 2 0 0 1-2 2h-2a2 2 0 0 1-2-2v-1","M14 8V7c0-1.1.9-2 2-2h2a2 2 0 0 1 2 2v1"],fills:[],accents:[]},Lb={name:"align-center-vertical",family:"ui",paths:["M12 2v20","M8 10H4a2 2 0 0 1-2-2V6c0-1.1.9-2 2-2h4","M16 10h4a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2h-4","M8 20H7a2 2 0 0 1-2-2v-2c0-1.1.9-2 2-2h1","M16 14h1a2 2 0 0 1 2 2v2a2 2 0 0 1-2 2h-1"],fills:[],accents:[]},Db={name:"align-end-horizontal",family:"ui",paths:["M6 2h2a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z","M16 9h2a2 2 0 0 1 2 2v5a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-5a2 2 0 0 1 2 -2z","M22 22H2"],fills:[],accents:[]},Hb={name:"align-end-vertical",family:"ui",paths:["M4 4h12a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M11 14h5a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M22 22V2"],fills:[],accents:[]},_b={name:"align-horizontal-justify-center",family:"ui",paths:["M4 5h2a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M18 7h2a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z","M12 2v20"],fills:[],accents:[]},Ub={name:"align-start-horizontal",family:"ui",paths:["M6 6h2a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z","M16 6h2a2 2 0 0 1 2 2v5a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-5a2 2 0 0 1 2 -2z","M22 2H2"],fills:[],accents:[]},Bb={name:"align-start-vertical",family:"ui",paths:["M8 14h5a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M8 4h12a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M2 2v20"],fills:[],accents:[]},Vb={name:"align-vertical-justify-center",family:"ui",paths:["M7 16h10a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M9 2h6a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M2 12h20"],fills:[],accents:[]},qb={name:"align-vertical-justify-end",family:"ui",paths:["M7 12h10a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M9 2h6a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M2 22h20"],fills:[],accents:[]},Gb={name:"align-vertical-justify-start",family:"ui",paths:["M7 16h10a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M9 6h6a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M2 2h20"],fills:[],accents:[]},Yb={name:"animation-appear",family:"tool",paths:["M9.5 7.5h5a2 2 0 0 1 2 2v5a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-5a2 2 0 0 1 2 -2z","M4 4l1.5 1.5","M20 4l-1.5 1.5","M4 20l1.5-1.5","M20 20l-1.5-1.5"],fills:[],accents:["M9.5 7.5h5a2 2 0 0 1 2 2v5a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-5a2 2 0 0 1 2 -2z"]},$b={name:"animation-fade",family:"tool",paths:["M7 5h10a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M12 5v14","M6.5 11l3-3","M6.5 15.5l4.5-4.5"],fills:[],accents:["M12 5h5a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-5z"]},Xb={name:"animation-fade-out",family:"tool",paths:["M7 5h10a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M12 5v14","M17.5 11l-3-3","M17.5 15.5l-4.5-4.5"],fills:[],accents:["M12 5H7a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h5z"]},Kb={name:"animation-float-in",family:"tool",paths:["M9.5 3.5h5a2 2 0 0 1 2 2v5a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-5a2 2 0 0 1 2 -2z","M7 16.5h10","M9.5 20h5"],fills:[],accents:["M9.5 3.5h5a2 2 0 0 1 2 2v5a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-5a2 2 0 0 1 2 -2z"]},Ib={name:"animation-fly-in",family:"tool",paths:["M13 3.5h5.5a2 2 0 0 1 2 2v5.5a2 2 0 0 1 -2 2h-5.5a2 2 0 0 1 -2 -2v-5.5a2 2 0 0 1 2 -2z","M3.5 20.5l4.5-4.5","M3.5 15.5l2.5-2.5","M8.5 20.5l2.5-2.5"],fills:[],accents:["M13 3.5h5.5a2 2 0 0 1 2 2v5.5a2 2 0 0 1 -2 2h-5.5a2 2 0 0 1 -2 -2v-5.5a2 2 0 0 1 2 -2z"]},Zb={name:"animation-fly-out",family:"tool",paths:["M13 11h5.5a2 2 0 0 1 2 2v5.5a2 2 0 0 1 -2 2h-5.5a2 2 0 0 1 -2 -2v-5.5a2 2 0 0 1 2 -2z","M3.5 3.5l4.5 4.5","M3.5 8.5l2.5 2.5","M8.5 3.5l2.5 2.5"],fills:[],accents:["M13 11h5.5a2 2 0 0 1 2 2v5.5a2 2 0 0 1 -2 2h-5.5a2 2 0 0 1 -2 -2v-5.5a2 2 0 0 1 2 -2z"]},Fb={name:"animation-grow-shrink",family:"tool",paths:["M5.5 13h4a1.5 1.5 0 0 1 1.5 1.5v4a1.5 1.5 0 0 1 -1.5 1.5h-4a1.5 1.5 0 0 1 -1.5 -1.5v-4a1.5 1.5 0 0 1 1.5 -1.5z","M13 11l6-6","M14.5 5H19v4.5","M21 13v5a2 2 0 0 1 -2 2h-5"],fills:[],accents:["M5.5 13h4a1.5 1.5 0 0 1 1.5 1.5v4a1.5 1.5 0 0 1 -1.5 1.5h-4a1.5 1.5 0 0 1 -1.5 -1.5v-4a1.5 1.5 0 0 1 1.5 -1.5z"]},Qb={name:"animation-path",family:"tool",paths:["M15 3.5h3.5a2 2 0 0 1 2 2v3.5a2 2 0 0 1 -2 2h-3.5a2 2 0 0 1 -2 -2v-3.5a2 2 0 0 1 2 -2z","M4.5 19.5h.01","M6 16.5h.01","M8 14h.01","M10.5 12.5h.01"],fills:["M3.25 19.5a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:["M15 3.5h3.5a2 2 0 0 1 2 2v3.5a2 2 0 0 1 -2 2h-3.5a2 2 0 0 1 -2 -2v-3.5a2 2 0 0 1 2 -2z"]},Jb={name:"animation-pulse",family:"tool",paths:["M10 8h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z","M7 4h10a3 3 0 0 1 3 3v10a3 3 0 0 1 -3 3h-10a3 3 0 0 1 -3 -3v-10a3 3 0 0 1 3 -3z"],fills:[],accents:["M10 8h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z"]},Pb={name:"animation-spin",family:"tool",paths:["M10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1 -1.5 1.5h-3a1.5 1.5 0 0 1 -1.5 -1.5v-3a1.5 1.5 0 0 1 1.5 -1.5z","M20 12a8 8 0 1 1 -8-8 8.7 8.7 0 0 1 6 2.5L20 8","M20 4v4h-4"],fills:[],accents:["M10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1 -1.5 1.5h-3a1.5 1.5 0 0 1 -1.5 -1.5v-3a1.5 1.5 0 0 1 1.5 -1.5z"]},Wb={name:"animation-split",family:"tool",paths:["M6 6.5h2a2 2 0 0 1 2 2v7a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-7a2 2 0 0 1 2 -2z","M16 6.5h2a2 2 0 0 1 2 2v7a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-7a2 2 0 0 1 2 -2z","M12 3v2","M12 19v2"],fills:[],accents:["M6 6.5h2a2 2 0 0 1 2 2v7a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-7a2 2 0 0 1 2 -2z","M16 6.5h2a2 2 0 0 1 2 2v7a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-7a2 2 0 0 1 2 -2z"]},e8={name:"animation-wipe",family:"tool",paths:["M6 5h12a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M12 5v14","m14.5 10 2 2-2 2"],fills:[],accents:["M12 5H6a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h6z"]},a8={name:"animation-zoom",family:"tool",paths:["M10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1 -1.5 1.5h-3a1.5 1.5 0 0 1 -1.5 -1.5v-3a1.5 1.5 0 0 1 1.5 -1.5z","M4 8V6a2 2 0 0 1 2-2h2","M16 4h2a2 2 0 0 1 2 2v2","M20 16v2a2 2 0 0 1 -2 2h-2","M8 20H6a2 2 0 0 1 -2-2v-2"],fills:[],accents:["M10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1 -1.5 1.5h-3a1.5 1.5 0 0 1 -1.5 -1.5v-3a1.5 1.5 0 0 1 1.5 -1.5z"]},t8={name:"aperture",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","m14.31 8 5.74 9.94","M9.69 8h11.48","m7.38 12 5.74-9.94","M9.69 16 3.95 6.06","M14.31 16H2.83","m16.62 12-5.74 9.94"],fills:[],accents:[]},n8={name:"app-window",family:"ui",paths:["M4 4h16a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z","M10 4v4","M2 8h20","M6 4v4"],fills:[],accents:[]},l8={name:"app-window-mac",family:"ui",paths:["M4 4h16a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z","M6 8h.01","M10 8h.01","M14 8h.01"],fills:[],accents:[]},i8={name:"arc",family:"tool",paths:["M4 17a9 9 0 0 1 16 0"],fills:["M2.75 17a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M10.75 9a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M18.75 17a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:[]},s8={name:"array-path",family:"tool",paths:["M3 19c4 0 6-14 18-14","M3.75 15h2a0.75 0.75 0 0 1 0.75 0.75v2a0.75 0.75 0 0 1 -0.75 0.75h-2a0.75 0.75 0 0 1 -0.75 -0.75v-2a0.75 0.75 0 0 1 0.75 -0.75z","M10.25 8.5h2a0.75 0.75 0 0 1 0.75 0.75v2a0.75 0.75 0 0 1 -0.75 0.75h-2a0.75 0.75 0 0 1 -0.75 -0.75v-2a0.75 0.75 0 0 1 0.75 -0.75z","M17.25 4h2a0.75 0.75 0 0 1 0.75 0.75v2a0.75 0.75 0 0 1 -0.75 0.75h-2a0.75 0.75 0 0 1 -0.75 -0.75v-2a0.75 0.75 0 0 1 0.75 -0.75z"],fills:[],accents:["M3.75 15h2a0.75 0.75 0 0 1 0.75 0.75v2a0.75 0.75 0 0 1 -0.75 0.75h-2a0.75 0.75 0 0 1 -0.75 -0.75v-2a0.75 0.75 0 0 1 0.75 -0.75z"]},r8={name:"array-polar",family:"tool",paths:["M17.75 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M14 5.5a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M6.5 5.5a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M2.75 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M6.5 18.5a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M14 18.5a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"],fills:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:["M17.75 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"]},u8={name:"array-rectangular",family:"tool",paths:["M5 4h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M11 4h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M17 4h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M5 10h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M11 10h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M17 10h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M5 16h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M11 16h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","M17 16h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z"],fills:[],accents:["M5 4h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z"]},z5={name:"arrow-down",family:"ui",paths:["M12 4.5v15","M6.5 14l5.5 5.5 5.5-5.5"],fills:[],accents:[]},c8={name:"arrow-down-a-z",family:"ui",paths:["m3 16 4 4 4-4","M7 20V4","M20 8h-5","M15 10V6.5a2.5 2.5 0 0 1 5 0V10","M15 14h5l-5 6h5"],fills:[],accents:[]},x5={name:"arrow-down-to-line",family:"ui",paths:["M12 17V3","m6 11 6 6 6-6","M19 21H5"],fills:[],accents:[]},o8={name:"arrow-down-wide-narrow",family:"ui",paths:["m3 16 4 4 4-4","M7 20V4","M11 4h10","M11 8h7","M11 12h4"],fills:[],accents:[]},C5={name:"arrow-left",family:"ui",paths:["m12 19-7-7 7-7","M19 12H5"],fills:[],accents:[]},f8={name:"arrow-left-from-line",family:"ui",paths:["m9 6-6 6 6 6","M3 12h14","M21 19V5"],fills:[],accents:[]},E5={name:"arrow-left-right",family:"ui",paths:["M4.5 8.5h15","M16 5l3.5 3.5L16 12","M19.5 15.5h-15","M8 12l-3.5 3.5L8 19"],fills:[],accents:[]},T5={name:"arrow-left-to-line",family:"ui",paths:["M3 19V5","m13 6-6 6 6 6","M7 12h14"],fills:[],accents:[]},k5={name:"arrow-right",family:"ui",paths:["M5 12h14","m12 5 7 7-7 7"],fills:[],accents:[]},d8={name:"arrow-right-from-line",family:"ui",paths:["M3 5v14","M21 12H7","m15 18 6-6-6-6"],fills:[],accents:[]},A5={name:"arrow-right-left",family:"ui",paths:["m16 3 4 4-4 4","M20 7H4","m8 21-4-4 4-4","M4 17h16"],fills:[],accents:[]},j5={name:"arrow-right-to-line",family:"ui",paths:["M17 12H3","m11 18 6-6-6-6","M21 5v14"],fills:[],accents:[]},N5={name:"arrow-up",family:"ui",paths:["M12 19.5V4.5","M6.5 10L12 4.5 17.5 10"],fills:[],accents:[]},O5={name:"arrow-up-down",family:"ui",paths:["m21 16-4 4-4-4","M17 20V4","m3 8 4-4 4 4","M7 4v16"],fills:[],accents:[]},h8={name:"arrow-up-right",family:"ui",paths:["M7 7h10v10","M7 17 17 7"],fills:[],accents:[]},m8={name:"at-sign",family:"ui",paths:["M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M16 8v5a3 3 0 0 0 6 0v-1a10 10 0 1 0-4 8"],fills:[],accents:[]},v8={name:"audio-lines",family:"ui",paths:["M2 10v3","M6 6v11","M10 3v18","M14 8v7","M18 5v13","M22 10v3"],fills:[],accents:[]},p8={name:"audio-waveform",family:"ui",paths:["M2 13a2 2 0 0 0 2-2V7a2 2 0 0 1 4 0v13a2 2 0 0 0 4 0V4a2 2 0 0 1 4 0v13a2 2 0 0 0 4 0v-4a2 2 0 0 1 2-2"],fills:[],accents:[]},y8={name:"ban",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M4.929 4.929 19.07 19.071"],fills:[],accents:[]},g8={name:"bandage",family:"ui",paths:["M10 10.01h.01","M10 14.01h.01","M14 10.01h.01","M14 14.01h.01","M18 6v12","M6 6v12","M4 6h16a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"],fills:[],accents:["M6 6h12v12H6z"]},M8={name:"baseline",family:"ui",paths:["M4 20h16","m6 16 6-12 6 12","M8 12h8"],fills:[],accents:["M12 4l4 8H8z"]},R5={name:"bell",family:"ui",paths:["M10.268 21a2 2 0 0 0 3.464 0","M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326"],fills:[],accents:[]},b8={name:"between-horizontal-end",family:"ui",paths:["M4 3h11a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-11a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","m22 15-3-3 3-3","M4 14h11a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-11a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z"],fills:[],accents:[]},w8={name:"between-horizontal-start",family:"ui",paths:["M9 3h11a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-11a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","m2 9 3 3-3 3","M9 14h11a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-11a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z"],fills:[],accents:[]},S8={name:"between-vertical-end",family:"ui",paths:["M4 3h5a1 1 0 0 1 1 1v11a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-11a1 1 0 0 1 1 -1z","m9 22 3-3 3 3","M15 3h5a1 1 0 0 1 1 1v11a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-11a1 1 0 0 1 1 -1z"],fills:[],accents:[]},z8={name:"between-vertical-start",family:"ui",paths:["M4 8h5a1 1 0 0 1 1 1v11a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-11a1 1 0 0 1 1 -1z","m15 2-3 3-3-3","M15 8h5a1 1 0 0 1 1 1v11a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-11a1 1 0 0 1 1 -1z"],fills:[],accents:[]},L5={name:"blend",family:"ui",paths:["M8 9a7 7 0 1 0 14 0a7 7 0 1 0 -14 0z","M2 15a7 7 0 1 0 14 0a7 7 0 1 0 -14 0z"],fills:[],accents:["M8.06 8.06A7 7 0 0 0 15.94 15.94A7 7 0 0 0 8.06 8.06z"]},x8={name:"blocks",family:"ui",paths:["M10 22V7a1 1 0 0 0-1-1H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-5a1 1 0 0 0-1-1H2","M15 2h6a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-6a1 1 0 0 1 1 -1z"],fills:[],accents:[]},D5={name:"bold",family:"ui",paths:["M6 12h9a4 4 0 0 1 0 8H7a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h7a4 4 0 0 1 0 8"],fills:[],accents:[]},C8={name:"book-bookmark",family:"ui",paths:["M10 2v7.751a.25.25 0 00.407.195l2.28-1.834a.5.5 0 01.627 0l2.28 1.834A.25.25 0 0016 9.751V2","M4 19.5v-15A2.5 2.5 0 016.5 2H19a1 1 0 011 1v18a1 1 0 01-1 1H6.5a1 1 0 010-5H20"],fills:[],accents:[]},H5={name:"book-open",family:"ui",paths:["M12 5v16","M20.001 19A2 2 0 0022 17V5a2 2 0 00-1.999-2L16 3.002A5 5 0 0012 5a5 5 0 00-4-2H4a2 2 0 00-2 2v12a2 2 0 001.999 2H8a5 5 0 014 2 5 5 0 014-2z"],fills:[],accents:[]},E8={name:"book-open-text",family:"ui",paths:["M12 5v16","M16 13h2","M16 9h2","M20.001 19A2 2 0 0022 17V5a2 2 0 00-1.999-2L16 3.002A5 5 0 0012 5a5 5 0 00-4-2H4a2 2 0 00-2 2v12a2 2 0 001.999 2H8a5 5 0 014 2 5 5 0 014-2z","M6 13h2","M6 9h2"],fills:[],accents:[]},_5={name:"bookmark",family:"ui",paths:["M17 3a2 2 0 0 1 2 2v15a1 1 0 0 1-1.496.868l-4.512-2.578a2 2 0 0 0-1.984 0l-4.512 2.578A1 1 0 0 1 5 20V5a2 2 0 0 1 2-2z"],fills:[],accents:[]},T8={name:"bot",family:"ui",paths:["M12 8V4H8","M6 8h12a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M2 14h2","M20 14h2","M15 13v2","M9 13v2"],fills:[],accents:[]},U5={name:"box",family:"ui",paths:["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","m3.3 7 8.7 5 8.7-5","M12 22V12"],fills:[],accents:[]},k8={name:"boxes",family:"ui",paths:["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","m7 16.5-4.74-2.85","m7 16.5 5-3","M7 16.5v5.17","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","m17 16.5-5-3","m17 16.5 4.74-2.85","M17 16.5v5.17","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","M12 8 7.26 5.15","m12 8 4.74-2.85","M12 13.5V8"],fills:[],accents:[]},B5={name:"braces",family:"ui",paths:["M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1","M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1"],fills:[],accents:[]},A8={name:"break-line",family:"tool",paths:["M4 18l5-5","M15 11l5-5","M10.5 8.5l1 1","M12.5 14.5l1 1"],fills:["M8 13a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M14 11a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:[]},j8={name:"briefcase",family:"ui",paths:["M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16","M4 6h16a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z"],fills:[],accents:[]},N8={name:"briefcase-business",family:"ui",paths:["M12 12h.01","M16 6V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v2","M22 13a18.15 18.15 0 0 1-20 0","M4 6h16a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z"],fills:[],accents:[]},V5={name:"bring-to-front",family:"ui",paths:["M10 8h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z","M4 10a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2","M14 20a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2"],fills:[],accents:[]},q5={name:"brush",family:"ui",paths:["m11 10 3 3","M6.5 21A3.5 3.5 0 1 0 3 17.5a2.62 2.62 0 0 1-.708 1.792A1 1 0 0 0 3 21z","M9.969 17.031 21.378 5.624a1 1 0 0 0-3.002-3.002L6.967 14.031"],fills:[],accents:["M6.5 21A3.5 3.5 0 1 0 3 17.5a2.62 2.62 0 0 1-.708 1.792A1 1 0 0 0 3 21z"]},O8={name:"brush-cleaning",family:"ui",paths:["m16 22-1-4","M19 14a1 1 0 0 0 1-1v-1a2 2 0 0 0-2-2h-3a1 1 0 0 1-1-1V4a2 2 0 0 0-4 0v5a1 1 0 0 1-1 1H6a2 2 0 0 0-2 2v1a1 1 0 0 0 1 1","M19 14H5l-1.973 6.767A1 1 0 0 0 4 22h16a1 1 0 0 0 .973-1.233z","m8 22 1-4"],fills:[],accents:["M19 14H5l-1.973 6.767A1 1 0 0 0 4 22h16a1 1 0 0 0 .973-1.233z"]},R8={name:"cable",family:"ui",paths:["M17 19a1 1 0 0 1-1-1v-2a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2a1 1 0 0 1-1 1z","M17 21v-2","M19 14V6.5a1 1 0 0 0-7 0v11a1 1 0 0 1-7 0V10","M21 21v-2","M3 5V3","M4 10a2 2 0 0 1-2-2V6a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2a2 2 0 0 1-2 2z","M7 5V3"],fills:[],accents:[]},G5={name:"calendar",family:"ui",paths:["M8 2v3","M16 2v3","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9h18"],fills:[],accents:[]},L8={name:"calendar-clock",family:"ui",paths:["M16 14v2.2l1.6 1","M16 2v3","M21 7.338V5a2 2 0 00-2-2H5a2 2 0 00-2 2v14a2 2 0 002 2h2.338","M3 9h5.859","M8 2v3","M10 16a6 6 0 1 0 12 0a6 6 0 1 0 -12 0z"],fills:[],accents:[]},D8={name:"calendar-days",family:"ui",paths:["M8 2v3","M16 2v3","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9h18","M8 13h.01","M12 13h.01","M16 13h.01","M8 17h.01","M12 17h.01","M16 17h.01"],fills:[],accents:[]},H8={name:"calendar-range",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M16 2v3","M3 9h18","M8 2v3","M17 13h-6","M13 17H7","M7 13h.01","M17 17h.01"],fills:[],accents:[]},Y5={name:"camera",family:"ui",paths:["M13.997 4a2 2 0 0 1 1.76 1.05l.486.9A2 2 0 0 0 18.003 7H20a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h1.997a2 2 0 0 0 1.759-1.048l.489-.904A2 2 0 0 1 10.004 4z","M9 13a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},_8={name:"captions",family:"ui",paths:["M5 5h14a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M7 15h4M15 15h2M7 11h2M13 11h4"],fills:[],accents:[]},U8={name:"case-lower",family:"ui",paths:["M10 9v7","M14 6v10","M14 12.5a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0z","M3 12.5a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0z"],fills:[],accents:[]},B8={name:"case-sensitive",family:"ui",paths:["m2 16 4.039-9.69a.5.5 0 0 1 .923 0L11 16","M22 9v7","M3.304 13h6.392","M15 12.5a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0z"],fills:[],accents:[]},V8={name:"case-upper",family:"ui",paths:["M15 11h4.5a1 1 0 0 1 0 5h-4a.5.5 0 0 1-.5-.5v-9a.5.5 0 0 1 .5-.5h3a1 1 0 0 1 0 5","m2 16 4.039-9.69a.5.5 0 0 1 .923 0L11 16","M3.304 13h6.392"],fills:[],accents:[]},q8={name:"center-line",family:"tool",paths:["M4 4v16","M20 4v16","M7 12h3","M12 12h.01","M14 12h3"],fills:[],accents:[]},G8={name:"center-mark",family:"tool",paths:["M6 12a6 6 0 1 0 12 0a6 6 0 1 0 -12 0z","M12 3v4","M12 17v4","M3 12h4","M17 12h4"],fills:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:[]},Y8={name:"chamfer",family:"tool",paths:["M5 20v-9l6-6h9"],fills:["M4 11a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M10 5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:[]},$8={name:"chart-area",family:"ui",paths:["M3 3v16a2 2 0 0 0 2 2h16","M7 11.207a.5.5 0 0 1 .146-.353l2-2a.5.5 0 0 1 .708 0l3.292 3.292a.5.5 0 0 0 .708 0l4.292-4.292a.5.5 0 0 1 .854.353V16a1 1 0 0 1-1 1H8a1 1 0 0 1-1-1z"],fills:[],accents:[]},$5={name:"chart-column",family:"ui",paths:["M3 3v16a2 2 0 0 0 2 2h16","M18 17V9","M13 17V5","M8 17v-3"],fills:[],accents:[]},X8={name:"chart-column-stacked",family:"ui",paths:["M11 13H7","M19 9h-4","M3 3v16a2 2 0 0 0 2 2h16","M16 5h2a1 1 0 0 1 1 1v10a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-10a1 1 0 0 1 1 -1z","M8 8h2a1 1 0 0 1 1 1v7a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-7a1 1 0 0 1 1 -1z"],fills:[],accents:[]},K8={name:"chart-gantt",family:"ui",paths:["M10 6h8","M12 16h6","M3 3v16a2 2 0 0 0 2 2h16","M8 11h7"],fills:[],accents:[]},I8={name:"chart-line",family:"ui",paths:["M3 3v16a2 2 0 0 0 2 2h16","m19 9-5 5-4-4-3 3"],fills:[],accents:[]},Z8={name:"chart-no-axes-column",family:"ui",paths:["M5 21v-6","M12 21V3","M19 21V9"],fills:[],accents:[]},F8={name:"chart-no-axes-combined",family:"ui",paths:["M12 16v5","M16 14.639V21","M20 10.656V21","m22 3-8.646 8.646a.5.5 0 0 1-.708 0L9.354 8.354a.5.5 0 0 0-.707 0L2 15","M4 18.463V21","M8 14.656V21"],fills:[],accents:[]},Q8={name:"chart-pie",family:"ui",paths:["M21 12c.552 0 1.005-.449.95-.998a10 10 0 0 0-8.953-8.951c-.55-.055-.998.398-.998.95v8a1 1 0 0 0 1 1z","M21.21 15.89A10 10 0 1 1 8 2.83"],fills:[],accents:[]},J8={name:"chart-scatter",family:"ui",paths:["M3 3v16a2 2 0 0 0 2 2h16"],fills:["M7 7.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z","M18 5.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z","M11 11.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z","M7 16.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z","M17 14.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z"],accents:[]},P8={name:"chart-spline",family:"ui",paths:["M3 3v16a2 2 0 0 0 2 2h16","M7 16c.5-2 1.5-7 4-7 2 0 2 3 4 3 2.5 0 4.5-5 5-7"],fills:[],accents:[]},X5={name:"check",family:"ui",paths:["M4.5 12.5l5 5 10-11"],fills:[],accents:[]},K5={name:"chevron-down",family:"ui",paths:["M6 9l6 6 6-6"],fills:[],accents:[]},W8={name:"chevron-first",family:"ui",paths:["m17 18-6-6 6-6","M7 6v12"],fills:[],accents:[]},e7={name:"chevron-last",family:"ui",paths:["m7 18 6-6-6-6","M17 6v12"],fills:[],accents:[]},I5={name:"chevron-left",family:"ui",paths:["m15 18-6-6 6-6"],fills:[],accents:[]},Z5={name:"chevron-right",family:"ui",paths:["m9 18 6-6-6-6"],fills:[],accents:[]},a7={name:"chevron-up",family:"ui",paths:["m18 15-6-6-6 6"],fills:[],accents:[]},F5={name:"chevrons-down-up",family:"ui",paths:["m7 20 5-5 5 5","m7 4 5 5 5-5"],fills:[],accents:[]},Q5={name:"chevrons-left",family:"ui",paths:["m11 17-5-5 5-5","m18 17-5-5 5-5"],fills:[],accents:[]},J5={name:"chevrons-right",family:"ui",paths:["m6 17 5-5-5-5","m13 17 5-5-5-5"],fills:[],accents:[]},t7={name:"chevrons-right-left",family:"ui",paths:["m20 17-5-5 5-5","m4 17 5-5-5-5"],fills:[],accents:[]},P5={name:"chevrons-up-down",family:"ui",paths:["m7 15 5 5 5-5","m7 9 5-5 5 5"],fills:[],accents:[]},W5={name:"circle",family:"ui",paths:["M3 12a9 9 0 1 0 18 0a9 9 0 1 0 -18 0z"],fills:[],accents:["M3 12a9 9 0 1 0 18 0a9 9 0 1 0 -18 0z"]},n7={name:"circle-alert",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M12 8L12 12","M12 16L12.01 16"],fills:[],accents:[]},l7={name:"circle-center-radius",family:"tool",paths:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M12 12h8"],fills:["M10.75 12a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z"]},i7={name:"circle-check",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","m16 9-5.5 5.5L8 12"],fills:[],accents:[]},s7={name:"circle-dashed",family:"ui",paths:["M10.1 2.182a10 10 0 0 1 3.8 0","M13.9 21.818a10 10 0 0 1-3.8 0","M17.609 3.721a10 10 0 0 1 2.69 2.7","M2.182 13.9a10 10 0 0 1 0-3.8","M20.279 17.609a10 10 0 0 1-2.7 2.69","M21.818 10.1a10 10 0 0 1 0 3.8","M3.721 6.391a10 10 0 0 1 2.7-2.69","M6.391 20.279a10 10 0 0 1-2.69-2.7"],fills:[],accents:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z"]},r7={name:"circle-dot",family:"ui",paths:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z"],fills:[],accents:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z"]},ev={name:"circle-question-mark",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3","M12 17h.01"],fills:[],accents:[]},u7={name:"circle-user-round",family:"ui",paths:["M17.925 20.056a6 6 0 0 0-11.851.001","M8 11a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z"],fills:[],accents:[]},c7={name:"circle-x",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","m15 9-6 6","m9 9 6 6"],fills:[],accents:[]},av={name:"clapperboard",family:"ui",paths:["m12.296 3.464 3.02 3.956","M20.2 6 3 11l-.9-2.4c-.3-1.1.3-2.2 1.3-2.5l13.5-4c1.1-.3 2.2.3 2.5 1.3z","M3 11h18v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z","m6.18 5.276 3.1 3.899"],fills:[],accents:[]},tv={name:"clip-extract",family:"tool",paths:["M12 12V3","m8.5 6.5 3.5-3.5 3.5 3.5","M3 17.5h6m6 0h6","m6.5 14.5 3 3-3 3m11-6-3 3 3 3"],fills:[],accents:[]},o7={name:"clip-insert",family:"tool",paths:["M12 3v9","m8.5 8.5 3.5 3.5 3.5-3.5","M3 15h5a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M16 15h5a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z"],fills:[],accents:[]},nv={name:"clip-lift",family:"tool",paths:["M12 13V3","m8.5 6.5 3.5-3.5 3.5 3.5","M3 15h5a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M16 15h5a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z"],fills:[],accents:[]},f7={name:"clip-overwrite",family:"tool",paths:["M12 3v8","m8.5 7.5 3.5 3.5 3.5-3.5","M4 14h16a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-16a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1z"],fills:[],accents:[]},lv={name:"clipboard",family:"ui",paths:["M9 2h6a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","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"],fills:[],accents:[]},d7={name:"clipboard-check",family:"ui",paths:["M9 2h6a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","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","m9 14 2 2 4-4"],fills:[],accents:[]},h7={name:"clipboard-list",family:"ui",paths:["M9 2h6a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z","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","M12 11h4","M12 16h4","M8 11h.01","M8 16h.01"],fills:[],accents:[]},iv={name:"clipboard-paste",family:"ui",paths:["M8 4H6.5a2 2 0 0 0 -2 2v13a2 2 0 0 0 2 2H10","M16 4h1.5a2 2 0 0 1 2 2v4","M9 2.5h6a1 1 0 0 1 1 1v1.5a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-1.5a1 1 0 0 1 1 -1z","M14 13h6a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-6a1 1 0 0 1 1 -1z"],fills:[],accents:[]},sv={name:"clock",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M12 6v6l4 2"],fills:[],accents:[]},m7={name:"clock-3",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M12 6v6h4"],fills:[],accents:[]},v7={name:"cloud",family:"ui",paths:["M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z"],fills:[],accents:["M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z"]},p7={name:"cloud-download",family:"ui",paths:["M12 13v8l-4-4","m12 21 4-4","M4.393 15.269A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.436 8.284"],fills:[],accents:[]},y7={name:"cloud-off",family:"ui",paths:["M10.94 5.274A7 7 0 0 1 15.71 10h1.79a4.5 4.5 0 0 1 4.222 6.057","M18.796 18.81A4.5 4.5 0 0 1 17.5 19H9A7 7 0 0 1 5.79 5.78","m2 2 20 20"],fills:[],accents:[]},g7={name:"cloud-upload",family:"ui",paths:["M12 13v8","M4 14.899A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.5 8.242","m8 17 4-4 4 4"],fills:[],accents:[]},M7={name:"cloudy",family:"ui",paths:["M17.5 12a1 1 0 1 1 0 9H9.006a7 7 0 1 1 6.702-9z","M21.832 9A3 3 0 0 0 19 7h-2.207a5.5 5.5 0 0 0-10.72.61"],fills:[],accents:[]},rv={name:"code",family:"ui",paths:["m16 18 6-6-6-6","m8 6-6 6 6 6"],fills:[],accents:[]},uv={name:"code-xml",family:"ui",paths:["m18 16 4-4-4-4","m6 8-4 4 4 4","m14.5 4-5 16"],fills:[],accents:[]},cv={name:"columns-2",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M12 3v18"],fills:[],accents:["M5 3h7v18H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"]},b7={name:"columns-3",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M9 3v18","M15 3v18"],fills:[],accents:[]},w7={name:"combine",family:"ui",paths:["M14 3a1 1 0 0 1 1 1v5a1 1 0 0 1-1 1","M19 3a1 1 0 0 1 1 1v5a1 1 0 0 1-1 1","m7 15 3 3","m7 21 3-3H5a2 2 0 0 1-2-2v-2","M15 14h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","M4 3h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z"],fills:[],accents:[]},S7={name:"command",family:"ui",paths:["M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3"],fills:[],accents:[]},ov={name:"command-generic",family:"ui",paths:["M7 5h10a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2-2v-10a2 2 0 0 1 2-2z"],fills:["M10.5 12a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z"],accents:[]},z7={name:"compass",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z"],fills:[],accents:[]},fv={name:"component",family:"ui",paths:["M15.536 11.293a1 1 0 0 0 0 1.414l2.376 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z","M2.297 11.293a1 1 0 0 0 0 1.414l2.377 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414L6.088 8.916a1 1 0 0 0-1.414 0z","M8.916 17.912a1 1 0 0 0 0 1.415l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.415l-2.377-2.376a1 1 0 0 0-1.414 0z","M8.916 4.674a1 1 0 0 0 0 1.414l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z"],fills:[],accents:[]},x7={name:"constraint-coincident",family:"tool",paths:["M4 19l8-7","M20 19l-8-7"],fills:["M10.25 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"],accents:[]},C7={name:"constraint-collinear",family:"tool",paths:["M3 20l6-6","M13 10l7-7"],fills:["M10.25 12a0.75 0.75 0 1 0 1.5 0a0.75 0.75 0 1 0 -1.5 0z"],accents:[]},E7={name:"constraint-concentric",family:"tool",paths:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z"],fills:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:[]},T7={name:"constraint-equal",family:"tool",paths:["M5 9h14","M5 15h14"],fills:[],accents:[]},k7={name:"constraint-fix",family:"tool",paths:["M12 6v7","M6 13h12","M8 13l-2 3","M12 13l-2 3","M16 13l-2 3"],fills:["M10.25 5a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"],accents:[]},A7={name:"constraint-horizontal",family:"tool",paths:["M5 12h14"],fills:["M3.25 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M17.25 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"],accents:[]},j7={name:"constraint-parallel",family:"tool",paths:["M5 20 13 4","M11 20 19 4"],fills:[],accents:[]},N7={name:"constraint-perpendicular",family:"tool",paths:["M5 19h14","M12 19V5","M12 15h3v4"],fills:[],accents:[]},O7={name:"constraint-symmetric",family:"tool",paths:["M12 3v2","M12 8v2","M12 14v2","M12 19v2","M8 12H5","M16 12h3"],fills:["M3.25 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M17.25 12a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"],accents:[]},R7={name:"constraint-tangent",family:"tool",paths:["M6 14a6 6 0 1 0 12 0a6 6 0 1 0 -12 0z","M3 8h18"],fills:[],accents:["M6 14a6 6 0 1 0 12 0a6 6 0 1 0 -12 0z"]},L7={name:"constraint-vertical",family:"tool",paths:["M12 5v14"],fills:["M10.25 5a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z","M10.25 19a1.75 1.75 0 1 0 3.5 0a1.75 1.75 0 1 0 -3.5 0z"],accents:[]},D7={name:"construction-line",family:"tool",paths:["M3 21 21 3","M3 17v4h4","M21 7V3h-4"],fills:["M10.5 12a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z"],accents:[]},H7={name:"contact",family:"ui",paths:["M16 2v2","M7 21v-2a2 2 0 012-2h6a2 2 0 012 2v2","M8 2v2","M9 10a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},dv={name:"contrast",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M12 18a6 6 0 0 0 0-12v12z"],fills:[],accents:[]},_7={name:"cookie",family:"ui",paths:["M11 17h.01","M11.496 2c.324-.016.558.292.529.615a4 4 0 004.235 4.368.713.713 0 01.758.757 4 4 0 004.366 4.237c.323-.03.63.204.614.527a10 10 0 01-2.915 6.566A1 1 0 114.93 4.918 10 10 0 0111.496 2","M12 12h.01","M16 16h.01","M16 3h.01","M21 4h.01","M21 8h.01","M7 14h.01","M9 8h.01"],fills:[],accents:[]},hv={name:"copy",family:"ui",paths:["M15 8V5a2 2 0 0 0 -2 -2H5a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h3","M10 8h9a2 2 0 0 1 2 2v9a2 2 0 0 1 -2 2h-9a2 2 0 0 1 -2 -2v-9a2 2 0 0 1 2 -2z"],fills:[],accents:["M10 8h9a2 2 0 0 1 2 2v9a2 2 0 0 1 -2 2h-9a2 2 0 0 1 -2 -2v-9a2 2 0 0 1 2 -2z"]},U7={name:"copy-check",family:"ui",paths:["m12 15 2 2 4-4","M10 8h10a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"],fills:[],accents:[]},mv={name:"copy-plus",family:"ui",paths:["M15 12L15 18","M12 15L18 15","M10 8h10a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"],fills:[],accents:["M10 8h10a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H10a2 2 0 0 1-2-2V10a2 2 0 0 1 2-2z"]},vv={name:"corner-down-right",family:"ui",paths:["m15 10 5 5-5 5","M4 4v7a4 4 0 0 0 4 4h12"],fills:[],accents:[]},B7={name:"corner-up-right",family:"ui",paths:["m15 14 5-5-5-5","M4 20v-7a4 4 0 0 1 4-4h12"],fills:[],accents:[]},V7={name:"cpu",family:"ui",paths:["M12 20v2","M12 2v2","M17 20v2","M17 2v2","M2 12h2","M2 17h2","M2 7h2","M20 12h2","M20 17h2","M20 7h2","M7 20v2","M7 2v2","M6 4h12a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z","M9 8h6a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-6a1 1 0 0 1 1 -1z"],fills:[],accents:[]},q7={name:"credit-card",family:"ui",paths:["M4 5h16a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M2 10L22 10","M6 14h2"],fills:[],accents:[]},pv={name:"crop",family:"ui",paths:["M6 2v14a2 2 0 0 0 2 2h14","M18 22V8a2 2 0 0 0-2-2H2"],fills:[],accents:["M6 6h12v12H6z"]},yv={name:"crosshair",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M22 12L18 12","M6 12L2 12","M12 6L12 2","M12 22L12 18"],fills:[],accents:[]},G7={name:"dash-dashed",family:"tool",paths:["M3 12h5M10 12h5M17 12h4"],fills:[],accents:[]},Y7={name:"dash-dotted",family:"tool",paths:["M4 12h.01M8 12h.01M12 12h.01M16 12h.01M20 12h.01"],fills:[],accents:[]},$7={name:"dash-solid",family:"tool",paths:["M3 12h18"],fills:[],accents:[]},gv={name:"database",family:"ui",paths:["M3 5a9 3 0 1 0 18 0a9 3 0 1 0 -18 0z","M3 5V19A9 3 0 0 0 21 19V5","M3 12A9 3 0 0 0 21 12"],fills:[],accents:[]},X7={name:"decimals-arrow-left",family:"ui",paths:["m13 21-3-3 3-3","M20 18H10","M3 11h.01","M8.5 3h0a2.5 2.5 0 0 1 2.5 2.5v3a2.5 2.5 0 0 1 -2.5 2.5h0a2.5 2.5 0 0 1 -2.5 -2.5v-3a2.5 2.5 0 0 1 2.5 -2.5z"],fills:[],accents:[]},K7={name:"decimals-arrow-right",family:"ui",paths:["M10 18h10","m17 21 3-3-3-3","M3 11h.01","M17.5 3h0a2.5 2.5 0 0 1 2.5 2.5v3a2.5 2.5 0 0 1 -2.5 2.5h0a2.5 2.5 0 0 1 -2.5 -2.5v-3a2.5 2.5 0 0 1 2.5 -2.5z","M8.5 3h0a2.5 2.5 0 0 1 2.5 2.5v3a2.5 2.5 0 0 1 -2.5 2.5h0a2.5 2.5 0 0 1 -2.5 -2.5v-3a2.5 2.5 0 0 1 2.5 -2.5z"],fills:[],accents:[]},I7={name:"delete",family:"ui",paths:["M10 5a2 2 0 0 0-1.344.519l-6.328 5.74a1 1 0 0 0 0 1.481l6.328 5.741A2 2 0 0 0 10 19h10a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2z","m12 9 6 6","m18 9-6 6"],fills:[],accents:[]},Mv={name:"diameter",family:"ui",paths:["M17 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3 5a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M6.48 3.66a10 10 0 0 1 13.86 13.86","m6.41 6.41 11.18 11.18","M3.66 6.48a10 10 0 0 0 13.86 13.86"],fills:[],accents:[]},bv={name:"diamond",family:"ui",paths:["M2.7 10.3a2.41 2.41 0 0 0 0 3.41l7.59 7.59a2.41 2.41 0 0 0 3.41 0l7.59-7.59a2.41 2.41 0 0 0 0-3.41l-7.59-7.59a2.41 2.41 0 0 0-3.41 0Z"],fills:[],accents:["M2.7 10.3a2.41 2.41 0 0 0 0 3.41l7.59 7.59a2.41 2.41 0 0 0 3.41 0l7.59-7.59a2.41 2.41 0 0 0 0-3.41l-7.59-7.59a2.41 2.41 0 0 0-3.41 0Z"]},Z7={name:"dimension-aligned",family:"tool",paths:["M5.5 15 15 5.5","M5.5 11.5V15H9","M15 9V5.5h-3.5","M3.5 13 8.5 18","M13 3.5l5 5"],fills:[],accents:["M9.5 20 20 9.5l1.5 1.5L11 21.5z"]},F7={name:"dimension-angular",family:"tool",paths:["M4 20h16","M4 20 15 6","M13 20a9 9 0 0 0 -3.4-7"],fills:[],accents:[]},Q7={name:"dimension-arc-length",family:"tool",paths:["M5 19a9 9 0 0 1 14 0","M3 13a12 12 0 0 1 18 0","M3 13v3","M21 13v3"],fills:[],accents:[]},J7={name:"dimension-baseline",family:"tool",paths:["M4 4v16","M4 8h6","M4 12.5h10.5","M4 17h16","M10 6.5v3","M14.5 11v3","M20 15.5v3"],fills:[],accents:[]},P7={name:"dimension-continue",family:"tool",paths:["M3 12h18","M3 9v6","M9 9v6","M15 9v6","M21 9v6"],fills:[],accents:[]},W7={name:"dimension-diameter",family:"tool",paths:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M6.5 17.5l11-11","M14.5 6.5h3v3","M9.5 17.5h-3v-3"],fills:[],accents:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z"]},ew={name:"dimension-linear",family:"tool",paths:["M5 4v9","M19 4v9","M5 8.5h14","m7.5 6.5-2.5 2 2.5 2","m16.5 6.5 2.5 2-2.5 2","M5 18h14"],fills:[],accents:["M5 16h14v4H5z"]},aw={name:"dimension-ordinate",family:"tool",paths:["M4 4v16h16","M10 10v6","M16 6v10"],fills:["M8.75 10a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M14.75 6a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:[]},tw={name:"dimension-radius",family:"tool",paths:["M3.5 13a7.5 7.5 0 1 0 15 0a7.5 7.5 0 1 0 -15 0z","M11 13l5.3-5.3","M14 7.5h2.5V10"],fills:["M10 13a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:["M3.5 13a7.5 7.5 0 1 0 15 0a7.5 7.5 0 1 0 -15 0z"]},wv={name:"disc",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M10 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},nw={name:"dollar-sign",family:"ui",paths:["M12 2L12 22","M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6"],fills:[],accents:[]},lw={name:"donut",family:"tool",paths:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z"],fills:[],accents:["M4 12a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z"]},Sv={name:"download",family:"ui",paths:["M12 4v11","M7.5 10.5l4.5 4.5 4.5-4.5","M4 15.5V18a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2.5"],fills:[],accents:[]},iw={name:"droplet",family:"ui",paths:["M12 22a7 7 0 0 0 7-7c0-2-1-3.9-3-5.5s-3.5-4-4-6.5c-.5 2.5-2 4.9-4 6.5C6 11.1 5 13 5 15a7 7 0 0 0 7 7z"],fills:[],accents:["M12 22a7 7 0 0 0 7-7c0-2-1-3.9-3-5.5s-3.5-4-4-6.5c-.5 2.5-2 4.9-4 6.5C6 11.1 5 13 5 15a7 7 0 0 0 7 7z"]},sw={name:"droplets",family:"ui",paths:["M7 16.3c2.2 0 4-1.83 4-4.05 0-1.16-.57-2.26-1.71-3.19S7.29 6.75 7 5.3c-.29 1.45-1.14 2.84-2.29 3.76S3 11.1 3 12.25c0 2.22 1.8 4.05 4 4.05z","M12.56 6.6A10.97 10.97 0 0 0 14 3.02c.5 2.5 2 4.9 4 6.5s3 3.5 3 5.5a6.98 6.98 0 0 1-11.91 4.97"],fills:[],accents:[]},rw={name:"earth",family:"ui",paths:["M21.54 15H17a2 2 0 0 0-2 2v4.54","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","M11 21.95V18a2 2 0 0 0-2-2a2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05","M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z"],fills:[],accents:[]},uw={name:"ellipse",family:"tool",paths:["M3 12a9 5.5 0 1 0 18 0a9 5.5 0 1 0 -18 0z","M12 12h9"],fills:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:["M3 12a9 5.5 0 1 0 18 0a9 5.5 0 1 0 -18 0z"]},zv={name:"ellipsis",family:"ui",paths:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M18 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M4 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],fills:[],accents:[]},cw={name:"ellipsis-vertical",family:"ui",paths:["M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M11 5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M11 19a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],fills:[],accents:[]},xv={name:"eraser",family:"ui",paths:["M14 4.5l6 6-9 9H7l-4-4z","M8 10.5l6 6","M13 19.5h7"],fills:[],accents:["M3 15.5l5-5 6 6-3 3H7z"]},ow={name:"expand",family:"ui",paths:["m15 15 6 6","m15 9 6-6","M21 16v5h-5","M21 8V3h-5","M3 16v5h5","m3 21 6-6","M3 8V3h5","M9 9 3 3"],fills:[],accents:[]},fw={name:"explode",family:"tool",paths:["M4 9V5a1 1 0 0 1 1-1h4","M15 4h4a1 1 0 0 1 1 1v4","M20 15v4a1 1 0 0 1 -1 1h-4","M9 20H5a1 1 0 0 1 -1-1v-4","M12 9v-1","M12 16v-1","M9 12h-1","M16 12h-1"],fills:[],accents:[]},dw={name:"extend",family:"tool",paths:["M20 4v16","M4 12h9","M15.5 12h.01","M17.5 12h.01"],fills:[],accents:[]},hw={name:"external-link",family:"ui",paths:["M15 3h6v6","M10 14 21 3","M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"],fills:[],accents:[]},Cv={name:"eye",family:"ui",paths:["M2.5 12C5 7.5 8.5 5.5 12 5.5s7 2 9.5 6.5c-2.5 4.5-6 6.5-9.5 6.5S5 16.5 2.5 12z","M9 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},Ev={name:"eye-off",family:"ui",paths:["M2.5 12C5 7.5 8.5 5.5 12 5.5s7 2 9.5 6.5c-2.5 4.5-6 6.5-9.5 6.5S5 16.5 2.5 12z","M4 4l16 16"],fills:[],accents:[]},mw={name:"face-slightly-smiling",family:"ui",paths:["M15 10V9","M16.472 15a6 6 0 01-8.943 0","M9 10V9","M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z"],fills:[],accents:[]},Tv={name:"fast-forward",family:"ui",paths:["M12 6a2 2 0 0 1 3.414-1.414l6 6a2 2 0 0 1 0 2.828l-6 6A2 2 0 0 1 12 18z","M2 6a2 2 0 0 1 3.414-1.414l6 6a2 2 0 0 1 0 2.828l-6 6A2 2 0 0 1 2 18z"],fills:[],accents:[]},kv={name:"feather",family:"ui",paths:["M14.086 18.412A2 2 0 0112.67 19H5v-7.672a2 2 0 01.586-1.414L11.75 3.75a6 6 0 118.49 8.49z","M16 8 2 22","M17.488 15H9"],fills:[],accents:[]},Av={name:"file",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5"],fills:[],accents:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z"]},vw={name:"file-archive",family:"ui",paths:["M13.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v11.5","M14 2v5a1 1 0 0 0 1 1h5","M8 12v-1","M8 18v-2","M8 7V6","M6 20a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},pw={name:"file-check-corner",family:"ui",paths:["M10.5 22H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v6","M14 2v5a1 1 0 0 0 1 1h5","m14 20 2 2 4-4"],fills:[],accents:[]},yw={name:"file-clock",family:"ui",paths:["M16 22h2a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v2.85","M14 2v5a1 1 0 0 0 1 1h5","M8 14v2.2l1.6 1","M2 16a6 6 0 1 0 12 0a6 6 0 1 0 -12 0z"],fills:[],accents:[]},jv={name:"file-code",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5","M10 12.5 8 15l2 2.5","m14 12.5 2 2.5-2 2.5"],fills:[],accents:[]},gw={name:"file-code-corner",family:"ui",paths:["M4 12.15V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2h-3.35","M14 2v5a1 1 0 0 0 1 1h5","m5 16-3 3 3 3","m9 22 3-3-3-3"],fills:[],accents:[]},Mw={name:"file-diff",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M9 10h6","M12 13V7","M9 17h6"],fills:[],accents:[]},bw={name:"file-digit",family:"ui",paths:["M4 12V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2","M14 2v5a1 1 0 0 0 1 1h5","M10 16h2v6","M10 22h4","M4 16h0a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h0a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z"],fills:[],accents:[]},ww={name:"file-exclamation-point",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M12 9v4","M12 17h.01"],fills:[],accents:[]},Sw={name:"file-image",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5","M8 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","m20 17-1.296-1.296a2.41 2.41 0 0 0-3.408 0L9 22"],fills:[],accents:[]},Nv={name:"file-input",family:"ui",paths:["M4 11V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2v-1","M14 2v5a1 1 0 0 0 1 1h5","M2 15h10","m9 18 3-3-3-3"],fills:[],accents:[]},Ov={name:"file-output",family:"ui",paths:["M4.226 20.925A2 2 0 0 0 6 22h12a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v3.127","M14 2v5a1 1 0 0 0 1 1h5","m5 11-3 3","m5 17-3-3h10"],fills:[],accents:[]},zw={name:"file-pen-line",family:"ui",paths:["M14.364 13.634a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506l4.013-4.009a1 1 0 0 0-3.004-3.004z","M14.487 7.858A1 1 0 0 1 14 7V2","M20 19.645V20a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l2.516 2.516","M8 18h1"],fills:[],accents:[]},Rv={name:"file-plus",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5","M9 15h6","M12 18v-6"],fills:[],accents:[]},Lv={name:"file-plus-corner",family:"ui",paths:["M11.35 22H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v5.35","M14 2v5a1 1 0 0 0 1 1h5","M14 19h6","M17 16v6"],fills:[],accents:[]},xw={name:"file-spreadsheet",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5","M8 13h2","M14 13h2","M8 17h2","M14 17h2"],fills:[],accents:[]},Cw={name:"file-symlink",family:"ui",paths:["M4 11V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h7","M14 2v5a1 1 0 0 0 1 1h5","m10 18 3-3-3-3"],fills:[],accents:[]},Ew={name:"file-text",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5","M10 9H8","M16 13H8","M16 17H8"],fills:[],accents:[]},Tw={name:"file-type-corner",family:"ui",paths:["M12 22h6a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v6","M14 2v5a1 1 0 0 0 1 1h5","M3 16v-1.5a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 .5.5V16","M6 22h2","M7 14v8"],fills:[],accents:[]},kw={name:"file-up",family:"ui",paths:["M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z","M14 2v5a1 1 0 0 0 1 1h5","M12 12v6","m15 15-3-3-3 3"],fills:[],accents:[]},Aw={name:"file-video-camera",family:"ui",paths:["M4 12V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2","M14 2v5a1 1 0 0 0 1 1h5","m10 17.843 3.033-1.755a.64.64 0 0 1 .967.56v4.704a.65.65 0 0 1-.967.56L10 20.157","M4 16h5a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1z"],fills:[],accents:[]},jw={name:"files",family:"ui",paths:["M15 2h-4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V8","M16.706 2.706A2.4 2.4 0 0 0 15 2v5a1 1 0 0 0 1 1h5a2.4 2.4 0 0 0-.706-1.706z","M5 7a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 1.732-1"],fills:[],accents:[]},Nw={name:"fillet",family:"tool",paths:["M5 20v-9a6 6 0 0 1 6-6h9"],fills:["M4 11a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M10 5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:[]},Dv={name:"film",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M7 3v18","M3 7.5h4","M3 12h18","M3 16.5h4","M17 3v18","M17 7.5h4","M17 16.5h4"],fills:[],accents:[]},Hv={name:"flag",family:"ui",paths:["M4 22V4a1 1 0 0 1 .4-.8A6 6 0 0 1 8 2c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10a1 1 0 0 1-.4.8A6 6 0 0 1 16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528"],fills:[],accents:[]},Ow={name:"flame",family:"ui",paths:["M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4"],fills:[],accents:["M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4z"]},Rw={name:"flask-conical",family:"ui",paths:["M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2","M6.453 15h11.094","M8.5 2h7"],fills:[],accents:[]},_v={name:"flip-horizontal",family:"ui",paths:["M12 3v2","M12 8v2","M12 13v2","M12 18v2","M9 6.5 3 17.5h6z","M15 6.5l6 11h-6z"],fills:[],accents:[]},Lw={name:"flower",family:"ui",paths:["M9 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M12 16.5A4.5 4.5 0 1 1 7.5 12 4.5 4.5 0 1 1 12 7.5a4.5 4.5 0 1 1 4.5 4.5 4.5 4.5 0 1 1-4.5 4.5","M12 7.5V9","M7.5 12H9","M16.5 12H15","M12 16.5V15","m8 8 1.88 1.88","M14.12 9.88 16 8","m8 16 1.88-1.88","M14.12 14.12 16 16"],fills:[],accents:[]},Uv={name:"focus",family:"ui",paths:["M9 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2"],fills:[],accents:[]},Dw={name:"fold-horizontal",family:"ui",paths:["M2 12h6","M22 12h-6","M12 2v2","M12 8v2","M12 14v2","M12 20v2","m19 9-3 3 3 3","m5 15 3-3-3-3"],fills:[],accents:[]},Bv={name:"folder",family:"ui",paths:["M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"],fills:[],accents:[]},Hw={name:"folder-check",family:"ui",paths:["M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z","m9 13 2 2 4-4"],fills:[],accents:[]},_w={name:"folder-input",family:"ui",paths:["M2 9V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2v-1","M2 13h10","m9 16 3-3-3-3"],fills:[],accents:[]},Uw={name:"folder-lock",family:"ui",paths:["M15 17h6a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M10 20H4a2 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.9H20a2 2 0 0 1 2 2v2.5","M20 17v-2a2 2 0 1 0-4 0v2"],fills:[],accents:[]},Vv={name:"folder-open",family:"ui",paths:["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"],fills:[],accents:[]},Bw={name:"folder-plus",family:"ui",paths:["M12 10v6","M9 13h6","M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"],fills:[],accents:[]},Vw={name:"folder-up",family:"ui",paths:["M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z","M12 10v6","m9 13 3-3 3 3"],fills:[],accents:[]},qv={name:"frame",family:"ui",paths:["M22 6L2 6","M22 18L2 18","M6 2L6 22","M18 2L18 22"],fills:[],accents:["M6 6h12v12H6z"]},qw={name:"fullscreen",family:"ui",paths:["M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2","M8 8h8a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-8a1 1 0 0 1 -1 -1v-6a1 1 0 0 1 1 -1z"],fills:[],accents:[]},Gv={name:"funnel",family:"ui",paths:["M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z"],fills:[],accents:[]},Gw={name:"gallery-horizontal-end",family:"ui",paths:["M2 7v10","M6 5v14","M12 3h8a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-8a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Yv={name:"gauge",family:"ui",paths:["m12 14 4-4","M3.34 19a10 10 0 1 1 17.32 0"],fills:[],accents:[]},$v={name:"gem",family:"ui",paths:["M10.5 3 8 9l4 13 4-13-2.5-6","M17 3a2 2 0 0 1 1.6.8l3 4a2 2 0 0 1 .013 2.382l-7.99 10.986a2 2 0 0 1-3.247 0l-7.99-10.986A2 2 0 0 1 2.4 7.8l2.998-3.997A2 2 0 0 1 7 3z","M2 9h20"],fills:[],accents:[]},Yw={name:"gift",family:"ui",paths:["M12 7v14","M20 11v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2v-8","M7.5 7a1 1 0 0 1 0-5A4.8 8 0 0 1 12 7a4.8 8 0 0 1 4.5-5 1 1 0 0 1 0 5","M4 7h16a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-16a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1z"],fills:[],accents:[]},$w={name:"git-branch",family:"ui",paths:["M15 6a9 9 0 0 0-9 9V3","M15 6a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M3 18a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},Xw={name:"git-branch-plus",family:"ui",paths:["M6 3v12","M18 9a3 3 0 1 0 0-6 3 3 0 0 0 0 6z","M6 21a3 3 0 1 0 0-6 3 3 0 0 0 0 6z","M15 6a9 9 0 0 0-9 9","M18 15v6","M21 18h-6"],fills:[],accents:[]},Kw={name:"git-compare",family:"ui",paths:["M15 18a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M3 6a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M13 6h3a2 2 0 0 1 2 2v7","M11 18H8a2 2 0 0 1-2-2V9"],fills:[],accents:[]},Iw={name:"glasses",family:"ui",paths:["M2 15a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M14 15a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M14 15a2 2 0 0 0-2-2 2 2 0 0 0-2 2","M2.5 13 5 7c.7-1.3 1.4-2 3-2","M21.5 13 19 7c-.7-1.3-1.5-2-3-2"],fills:[],accents:[]},Zw={name:"globe",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20","M2 12h20"],fills:[],accents:[]},Fw={name:"go-to-in",family:"tool",paths:["M8 4H6v16h2","M20 12h-9","m14 8-4 4 4 4"],fills:[],accents:[]},Qw={name:"go-to-out",family:"tool",paths:["M16 4h2v16h-2","M4 12h9","m10 8 4 4-4 4"],fills:[],accents:[]},Jw={name:"graduation-cap",family:"ui",paths:["M21.42 10.922a1 1 0 0 0-.019-1.838L12.83 5.18a2 2 0 0 0-1.66 0L2.6 9.08a1 1 0 0 0 0 1.832l8.57 3.908a2 2 0 0 0 1.66 0z","M22 10v6","M6 12.5V16a6 3 0 0 0 12 0v-3.5"],fills:[],accents:[]},Xv={name:"grid-2x2",family:"ui",paths:["M12 3v18","M3 12h18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Pw={name:"grid-3x2",family:"ui",paths:["M15 3v18","M3 12h18","M9 3v18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Kv={name:"grid-3x3",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9h18","M3 15h18","M9 3v18","M15 3v18"],fills:[],accents:[]},Ww={name:"grip-horizontal",family:"ui",paths:["M11 9a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M18 9a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M4 9a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M11 15a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M18 15a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M4 15a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],fills:[],accents:[]},e9={name:"grip-vertical",family:"ui",paths:["M8 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M8 5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M8 19a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M14 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M14 5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M14 19a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],fills:[],accents:[]},Iv={name:"group",family:"ui",paths:["M3 7V5a2 2 0 0 1 2 -2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1 -2 2h-2","M7 21H5a2 2 0 0 1 -2 -2v-2","M7 6h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M14 13h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z"],fills:[],accents:[]},Zv={name:"hand",family:"ui",paths:["M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2","M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2","M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8","M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15"],fills:[],accents:[]},a9={name:"hard-drive",family:"ui",paths:["M10 16h.01","M2.212 11.577a2 2 0 0 0-.212.896V18a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-5.527a2 2 0 0 0-.212-.896L18.55 5.11A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z","M21.946 12.013H2.054","M6 16h.01"],fills:[],accents:[]},Fv={name:"hash",family:"ui",paths:["M4.5 9h15","M4.5 15h15","M10 4L8 20","M16 4L14 20"],fills:[],accents:[]},t9={name:"hatch",family:"tool",paths:["M6 4h12a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z","M4.5 10.5 10.5 4.5","M4.5 16 16 4.5","M8 19.5 19.5 8","M13.5 19.5l6-6"],fills:[],accents:["M6 4h12a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z"]},Qv={name:"heading",family:"ui",paths:["M6 12h12","M6 20V4","M18 20V4"],fills:[],accents:[]},n9={name:"heart",family:"ui",paths:["M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5"],fills:[],accents:["M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5z"]},l9={name:"helix",family:"tool",paths:["M6 4c6 0 12 1.5 12 3.5S6 10 6 12s12 2.5 12 4.5S12 20 6 20"],fills:[],accents:[]},i9={name:"hexagon",family:"ui",paths:["M21 16V8a2 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"],fills:[],accents:["M21 16V8a2 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"]},Jv={name:"highlighter",family:"ui",paths:["M14.5 4.5l5 5-7 7-5-5z","M7.5 11.5l-3 3V17h4l3-3","M3.5 20.5h8"],fills:[],accents:["M7.5 11.5l-3 3V17h4l3-3z"]},s9={name:"hourglass",family:"ui",paths:["M5 22h14","M5 2h14","M17 22v-4.172a2 2 0 0 0-.586-1.414L12 12l-4.414 4.414A2 2 0 0 0 7 17.828V22","M7 2v4.172a2 2 0 0 0 .586 1.414L12 12l4.414-4.414A2 2 0 0 0 17 6.172V2"],fills:[],accents:[]},Pv={name:"image",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M7.5 9a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z","M3.5 18l5-5 3.5 3.5 4.5-4.5 4.5 4.5"],fills:[],accents:[]},r9={name:"image-down",family:"ui",paths:["M10.3 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v10l-3.1-3.1a2 2 0 0 0-2.814.014L6 21","m14 19 3 3v-5.5","m17 22 3-3","M7 9a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},Wv={name:"image-plus",family:"ui",paths:["M16 5h6","M19 2v6","M21 11.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7.5","m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21","M7 9a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},u9={name:"image-up",family:"ui",paths:["M10.3 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v10l-3.1-3.1a2 2 0 0 0-2.814.014L6 21","m14 19.5 3-3 3 3","M17 22v-5.5","M7 9a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},c9={name:"images",family:"ui",paths:["m22 11-1.296-1.296a2.4 2.4 0 0 0-3.408 0L11 16","M4 8a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2","M10 2h10a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z"],fills:["M12 7a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],accents:[]},o9={name:"inbox",family:"ui",paths:["M22 12L16 12L14 15L10 15L8 12L2 12","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"],fills:[],accents:[]},ep={name:"info",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M12 16v-4","M12 8h.01"],fills:[],accents:[]},ap={name:"italic",family:"ui",paths:["M19 4L10 4","M14 20L5 20","M15 4L9 20"],fills:[],accents:[]},f9={name:"key-round",family:"ui",paths:["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"],fills:["M16 7.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z"],accents:[]},d9={name:"keyboard",family:"ui",paths:["M10 8h.01","M12 12h.01","M14 8h.01","M16 12h.01","M18 8h.01","M6 8h.01","M7 16h10","M8 12h.01","M4 4h16a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z"],fills:[],accents:[]},h9={name:"keyframe",family:"tool",paths:["M12 4l8 8-8 8-8-8z"],fills:[],accents:[]},m9={name:"keyframe-next",family:"tool",paths:[],fills:["M8 6v12l9-6z"],accents:[]},v9={name:"keyframe-on",family:"tool",paths:[],fills:["M12 4l8 8-8 8-8-8z"],accents:[]},p9={name:"keyframe-previous",family:"tool",paths:[],fills:["M16 6v12l-9-6z"],accents:[]},y9={name:"lamp",family:"ui",paths:["M12 12v6","M4.077 10.615A1 1 0 0 0 5 12h14a1 1 0 0 0 .923-1.385l-3.077-7.384A2 2 0 0 0 15 2H9a2 2 0 0 0-1.846 1.23Z","M8 20a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v1a1 1 0 0 1-1 1H9a1 1 0 0 1-1-1z"],fills:[],accents:[]},tp={name:"languages",family:"ui",paths:["m5 8 6 6","m4 14 6-6 2-3","M2 5h12","M7 2h1","m22 22-5-10-5 10","M14 18h6"],fills:[],accents:[]},g9={name:"laptop",family:"ui",paths:["M18 5a2 2 0 0 1 2 2v8.526a2 2 0 0 0 .212.897l1.068 2.127a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45l1.068-2.127A2 2 0 0 0 4 15.526V7a2 2 0 0 1 2-2z","M20.054 15.987H3.946"],fills:[],accents:[]},np={name:"lasso",family:"ui",paths:["M3.704 14.467a10 8 0 1 1 3.115 2.375","M7 22a5 5 0 0 1-2-3.994","M3 16a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:["M2 10a10 8 0 1 0 20 0a10 8 0 1 0 -20 0z"]},M9={name:"lasso-select",family:"ui",paths:["M7 22a5 5 0 0 1-2-4","M7 16.93c.96.43 1.96.74 2.99.91","M3.34 14A6.8 6.8 0 0 1 2 10c0-4.42 4.48-8 10-8s10 3.58 10 8a7.19 7.19 0 0 1-.33 2","M5 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4z","M14.33 22h-.09a.35.35 0 0 1-.24-.32v-10a.34.34 0 0 1 .33-.34c.08 0 .15.03.21.08l7.34 6a.33.33 0 0 1-.21.59h-4.49l-2.57 3.85a.35.35 0 0 1-.28.14z"],fills:[],accents:["M2 10c0-4.42 4.48-8 10-8s10 3.58 10 8-4.48 8-10 8S2 14.42 2 10z"]},lp={name:"layers",family:"ui",paths:["M12 3.5l8.5 4.5-8.5 4.5-8.5-4.5z","M3.5 12l8.5 4.5 8.5-4.5","M3.5 16l8.5 4.5 8.5-4.5"],fills:[],accents:[]},b9={name:"layers-2",family:"ui",paths:["M13 13.74a2 2 0 0 1-2 0L2.5 8.87a1 1 0 0 1 0-1.74L11 2.26a2 2 0 0 1 2 0l8.5 4.87a1 1 0 0 1 0 1.74z","m20 14.285 1.5.845a1 1 0 0 1 0 1.74L13 21.74a2 2 0 0 1-2 0l-8.5-4.87a1 1 0 0 1 0-1.74l1.5-.845"],fills:[],accents:[]},w9={name:"layers-plus",family:"ui",paths:["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 .83.18 2 2 0 0 0 .83-.18l8.58-3.9a1 1 0 0 0 0-1.831z","M16 17h6","M19 14v6","M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 .825.178","M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l2.116-.962"],fills:[],accents:[]},S9={name:"layout-dashboard",family:"ui",paths:["M4 3h5a1 1 0 0 1 1 1v7a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-7a1 1 0 0 1 1 -1z","M15 3h5a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M15 12h5a1 1 0 0 1 1 1v7a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-7a1 1 0 0 1 1 -1z","M4 16h5a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z"],fills:[],accents:[]},z9={name:"layout-grid",family:"ui",paths:["M4 3h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","M15 3h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","M15 14h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","M4 14h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z"],fills:[],accents:[]},x9={name:"layout-panel-left",family:"ui",paths:["M4 3h5a1 1 0 0 1 1 1v16a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-16a1 1 0 0 1 1 -1z","M15 3h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","M15 14h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z"],fills:[],accents:[]},ip={name:"layout-template",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9.5h18","M10.5 9.5V21"],fills:[],accents:[]},C9={name:"leader",family:"tool",paths:["M4 20 11 12h9","M4 16v4h4","M12 8.5h8","M12 5h5"],fills:[],accents:[]},E9={name:"lengthen",family:"tool",paths:["M8 12h8","m5 9-3 3 3 3","m19 9 3 3-3 3"],fills:[],accents:[]},T9={name:"library",family:"ui",paths:["m16 6 4 14","M12 6v14","M8 8v12","M4 4v16"],fills:[],accents:[]},sp={name:"life-buoy",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","m4.93 4.93 4.24 4.24","m14.83 9.17 4.24-4.24","m14.83 14.83 4.24 4.24","m9.17 14.83-4.24 4.24","M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z"],fills:[],accents:[]},k9={name:"ligature",family:"ui",paths:["M14 12h2v8","M14 20h4","M6 12h4","M6 20h4","M8 20V8a4 4 0 0 1 7.464-2"],fills:[],accents:[]},rp={name:"lightbulb",family:"ui",paths:["M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5","M9 18h6","M10 22h4"],fills:[],accents:[]},A9={name:"line-segment",family:"tool",paths:["M5 19 19 5"],fills:["M3.5 19a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z","M17.5 5a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z"],accents:[]},j9={name:"linetype",family:"tool",paths:["M4 6h16","M4 12h4","M10 12h4","M16 12h4","M4 18h.01","M8 18h.01","M12 18h.01","M16 18h.01","M20 18h.01"],fills:[],accents:[]},N9={name:"lineweight",family:"tool",paths:["M4 6h16"],fills:["M4 10.5h16v1.5H4z","M4 15.5h16v3H4z"],accents:[]},up={name:"link",family:"ui",paths:["M10 7.5H7.5a4.5 4.5 0 0 0 0 9H10","M14 7.5h2.5a4.5 4.5 0 0 1 0 9H14","M8.5 12h7"],fills:[],accents:[]},cp={name:"link-2",family:"ui",paths:["M9 17H7A5 5 0 0 1 7 7h2","M15 7h2a5 5 0 1 1 0 10h-2","M8 12L16 12"],fills:[],accents:[]},op={name:"list",family:"ui",paths:["M3 5h.01","M3 12h.01","M3 19h.01","M8 5h13","M8 12h13","M8 19h13"],fills:[],accents:[]},O9={name:"list-checks",family:"ui",paths:["M13 5h8","M13 12h8","M13 19h8","m3 17 2 2 4-4","m3 7 2 2 4-4"],fills:[],accents:[]},R9={name:"list-filter",family:"ui",paths:["M2 5h20","M6 12h12","M9 19h6"],fills:[],accents:[]},L9={name:"list-indent-decrease",family:"ui",paths:["M21 5H11","M21 12H11","M21 19H11","m7 8-4 4 4 4"],fills:[],accents:[]},D9={name:"list-indent-increase",family:"ui",paths:["M21 5H11","M21 12H11","M21 19H11","m3 8 4 4-4 4"],fills:[],accents:[]},fp={name:"list-ordered",family:"ui",paths:["M11 5h10","M11 12h10","M11 19h10","M4 4h1v5","M4 9h2","M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02"],fills:[],accents:[]},H9={name:"list-plus",family:"ui",paths:["M16 5H3","M11 12H3","M16 19H3","M18 9v6","M21 12h-6"],fills:[],accents:[]},_9={name:"list-restart",family:"ui",paths:["M21 5H3","M7 12H3","M7 19H3","M12 18a5 5 0 0 0 9-3 4.5 4.5 0 0 0-4.5-4.5c-1.33 0-2.54.54-3.41 1.41L11 14","M11 10v4h4"],fills:[],accents:[]},U9={name:"list-todo",family:"ui",paths:["M13 5h8","M13 12h8","M13 19h8","m3 17 2 2 4-4","M4 4h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1z"],fills:[],accents:[]},dp={name:"list-tree",family:"ui",paths:["M8 5h13","M13 12h8","M13 19h8","M3 10a2 2 0 0 0 2 2h3","M3 5v12a2 2 0 0 0 2 2h3"],fills:[],accents:[]},B9={name:"list-video",family:"ui",paths:["M21 5H3","M10 12H3","M10 19H3","M15 12.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997a1 1 0 0 1-1.517-.86z"],fills:[],accents:[]},hp={name:"loader-circle",family:"ui",paths:["M21 12a9 9 0 1 1-6.219-8.56"],fills:[],accents:[]},mp={name:"lock",family:"ui",paths:["M6 11h12a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z","M8 11V7.5a4 4 0 0 1 8 0V11","M12 15v2"],fills:[],accents:[]},V9={name:"lock-keyhole",family:"ui",paths:["M11 16a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M5 10h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M7 10V7a5 5 0 0 1 10 0v3"],fills:[],accents:[]},vp={name:"lock-open",family:"ui",paths:["M6 11h12a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z","M8 11V7.5a4 4 0 0 1 8 0","M12 15v2"],fills:[],accents:[]},q9={name:"log-out",family:"ui",paths:["m16 17 5-5-5-5","M21 12H9","M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"],fills:[],accents:[]},G9={name:"lollipop",family:"ui",paths:["M3 11a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","m21 21-4.3-4.3","M11 11a2 2 0 0 0 4 0 4 4 0 0 0-8 0 6 6 0 0 0 12 0"],fills:[],accents:["M3 11a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z"]},pp={name:"magnet",family:"ui",paths:["m12 15 4 4","M2.352 10.648a1.205 1.205 0 0 0 0 1.704l2.296 2.296a1.205 1.205 0 0 0 1.704 0l6.029-6.029a1 1 0 1 1 3 3l-6.029 6.029a1.205 1.205 0 0 0 0 1.704l2.296 2.296a1.205 1.205 0 0 0 1.704 0l6.365-6.367A1 1 0 0 0 8.716 4.282z","m5 8 4 4"],fills:[],accents:[]},yp={name:"mail",family:"ui",paths:["m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7","M4 4h16a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Y9={name:"mail-warning",family:"ui",paths:["M22 10.5V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12.5","m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7","M20 14v4","M20 22v.01"],fills:[],accents:[]},$9={name:"map-pin",family:"ui",paths:["M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0","M9 10a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},X9={name:"mark-in",family:"tool",paths:["M14 4h-3a1 1 0 0 0-1 1v5.5L8 12l2 1.5V19a1 1 0 0 0 1 1h3"],fills:[],accents:[]},K9={name:"mark-out",family:"tool",paths:["M10 4h3a1 1 0 0 1 1 1v5.5l2 1.5-2 1.5V19a1 1 0 0 1-1 1h-3"],fills:[],accents:[]},I9={name:"maximize",family:"ui",paths:["M8 3H5a2 2 0 0 0-2 2v3","M21 8V5a2 2 0 0 0-2-2h-3","M3 16v3a2 2 0 0 0 2 2h3","M16 21h3a2 2 0 0 0 2-2v-3"],fills:[],accents:[]},Z9={name:"maximize-2",family:"ui",paths:["M15 3h6v6","m21 3-7 7","m3 21 7-7","M9 21H3v-6"],fills:[],accents:[]},F9={name:"megaphone",family:"ui",paths:["M11 6a13 13 0 0 0 8.4-2.8A1 1 0 0 1 21 4v12a1 1 0 0 1-1.6.8A13 13 0 0 0 11 14H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2z","M6 14a12 12 0 0 0 2.4 7.2 2 2 0 0 0 3.2-2.4A8 8 0 0 1 10 14","M8 6v8"],fills:[],accents:[]},gp={name:"menu",family:"ui",paths:["M4 5h16","M4 12h16","M4 19h16"],fills:[],accents:[]},Mp={name:"merge",family:"ui",paths:["m8 6 4-4 4 4","M12 2v10.3a4 4 0 0 1-1.172 2.872L4 22","m20 22-5-5"],fills:[],accents:[]},bp={name:"message-square",family:"ui",paths:["M6 4h13a2 2 0 0 1 2 2v9a2 2 0 0 1 -2 2H9.5L4 21V6a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Q9={name:"message-square-dashed",family:"ui",paths:["M14 3h2","M16 19h-2","M2 12v-2","M2 16v5.286a.71.71 0 0 0 1.212.502l1.149-1.149","M20 19a2 2 0 0 0 2-2v-1","M22 10v2","M22 6V5a2 2 0 0 0-2-2","M4 3a2 2 0 0 0-2 2v1","M8 19h2","M8 3h2"],fills:[],accents:[]},J9={name:"message-square-plus",family:"ui",paths:["M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z","M12 8v6","M9 11h6"],fills:[],accents:[]},P9={name:"message-square-text",family:"ui",paths:["M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z","M7 11h10","M7 15h6","M7 7h8"],fills:[],accents:[]},wp={name:"minimize-2",family:"ui",paths:["m14 10 7-7","M20 10h-6V4","m3 21 7-7","M4 14h6v6"],fills:[],accents:[]},Sp={name:"minus",family:"ui",paths:["M4.5 12h15"],fills:[],accents:[]},W9={name:"monitor",family:"ui",paths:["M4 3h16a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z","M8 21L16 21","M12 17L12 21"],fills:[],accents:[]},eS={name:"monitor-cog",family:"ui",paths:["M12 17v4","m14.305 7.53.923-.382","m15.228 4.852-.923-.383","m16.852 3.228-.383-.924","m16.852 8.772-.383.923","m19.148 3.228.383-.924","m19.53 9.696-.382-.924","m20.772 4.852.924-.383","m20.772 7.148.924.383","M22 13v2a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7","M8 21h8","M15 6a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},aS={name:"monitor-play",family:"ui",paths:["M15.033 9.44a.647.647 0 0 1 0 1.12l-4.065 2.352a.645.645 0 0 1-.968-.56V7.648a.645.645 0 0 1 .967-.56z","M12 17v4","M8 21h8","M4 3h16a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-10a2 2 0 0 1 2 -2z"],fills:[],accents:[]},tS={name:"monitor-smartphone",family:"ui",paths:["M18 8V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h8","M10 19v-3.96 3.15","M7 19h5","M18 12h2a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z"],fills:[],accents:[]},nS={name:"moon",family:"ui",paths:["M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401"],fills:[],accents:[]},lS={name:"mountain",family:"ui",paths:["m8 3 4 8 5-5 5 15H2L8 3z"],fills:[],accents:[]},iS={name:"mountain-snow",family:"ui",paths:["m8 3 4 8 5-5 5 15H2L8 3z","M4.14 15.08c2.62-1.57 5.24-1.43 7.86.42 2.74 1.94 5.49 2 8.23.19"],fills:[],accents:[]},zp={name:"mouse-pointer",family:"ui",paths:["M12.586 12.586 19 19","M3.688 3.037a.497.497 0 0 0-.651.651l6.5 15.999a.501.501 0 0 0 .947-.062l1.569-6.083a2 2 0 0 1 1.448-1.479l6.124-1.579a.5.5 0 0 0 .063-.947z"],fills:[],accents:["M3.688 3.037a.497.497 0 0 0-.651.651l6.5 15.999a.501.501 0 0 0 .947-.062l1.569-6.083a2 2 0 0 1 1.448-1.479l6.124-1.579a.5.5 0 0 0 .063-.947z"]},xp={name:"mouse-pointer-2",family:"ui",paths:["M4.5 4.5l15 6-6.5 2.5-2.5 6.5z"],fills:[],accents:["M4.5 4.5l15 6-6.5 2.5-2.5 6.5z"]},Cp={name:"mouse-pointer-click",family:"ui",paths:["M14 4.1 12 6","m5.1 8-2.9-.8","m6 12-1.9 2","M7.2 2.2 8 5.1","M9.037 9.69a.498.498 0 0 1 .653-.653l11 4.5a.5.5 0 0 1-.074.949l-4.349 1.041a1 1 0 0 0-.74.739l-1.04 4.35a.5.5 0 0 1-.95.074z"],fills:[],accents:[]},Ep={name:"move",family:"ui",paths:["M12 2v20","m15 19-3 3-3-3","m19 9 3 3-3 3","M2 12h20","m5 9-3 3 3 3","m9 5 3-3 3 3"],fills:[],accents:[]},Tp={name:"move-3d",family:"ui",paths:["M5 3v16h16","m5 19 6-6","m2 6 3-3 3 3","m18 16 3 3-3 3"],fills:[],accents:[]},kp={name:"move-horizontal",family:"ui",paths:["m18 8 4 4-4 4","M2 12h20","m6 8-4 4 4 4"],fills:[],accents:[]},sS={name:"move-right",family:"ui",paths:["M18 8L22 12L18 16","M2 12H22"],fills:[],accents:[]},Ap={name:"move-up-right",family:"ui",paths:["M13 5H19V11","M19 5L5 19"],fills:[],accents:[]},rS={name:"move-vertical",family:"ui",paths:["M12 2v20","m8 18 4 4 4-4","m8 6 4-4 4 4"],fills:[],accents:[]},uS={name:"multiline",family:"tool",paths:["M3 15l6-6h6l6 6","M3 20l6-6h6l6 6"],fills:[],accents:[]},jp={name:"music",family:"ui",paths:["M9 18V5l12-2v13","M3 18a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M15 16a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:["M3 18a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M15 16a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"]},cS={name:"navigation",family:"ui",paths:["M3 11L22 2L13 21L11 13L3 11z"],fills:[],accents:[]},Np={name:"network",family:"ui",paths:["M17 16h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1z","M3 16h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1z","M10 2h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1z","M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3","M12 12V8"],fills:[],accents:["M10 2h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1h-4a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1z"]},oS={name:"notebook-pen",family:"ui",paths:["M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4","M2 6h4","M2 10h4","M2 14h4","M2 18h4","M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z"],fills:[],accents:[]},fS={name:"notebook-text",family:"ui",paths:["M2 6h4","M2 10h4","M2 14h4","M2 18h4","M6 2h12a2 2 0 0 1 2 2v16a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-16a2 2 0 0 1 2 -2z","M9.5 8h5","M9.5 12H16","M9.5 16H14"],fills:[],accents:[]},dS={name:"offset",family:"tool",paths:["M4 17c4-8 12-8 16 0","M4 11c4-8 12-8 16 0","M12 9v2.5","m10.5 10 1.5 1.5 1.5-1.5"],fills:[],accents:[]},Op={name:"omega",family:"ui",paths:["M3 20h4.5a.5.5 0 0 0 .5-.5v-.282a.52.52 0 0 0-.247-.437 8 8 0 1 1 8.494-.001.52.52 0 0 0-.247.438v.282a.5.5 0 0 0 .5.5H21"],fills:[],accents:[]},hS={name:"orbit",family:"ui",paths:["M20.341 6.484A10 10 0 0 1 10.266 21.85","M3.659 17.516A10 10 0 0 1 13.74 2.152","M9 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M17 5a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},mS={name:"ortho-mode",family:"tool",paths:["M5 4v15h15","M5 15h4v4"],fills:[],accents:[]},Rp={name:"package",family:"ui",paths:["M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 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.73z","M12 22V12","M3.29 7L12 12L20.71 7","m7.5 4.27 9 5.15"],fills:[],accents:["M3.29 7L12 12v10L4 17.73A2 2 0 0 1 3 16V8a2 2 0 0 1 .29-1z"]},Lp={name:"paint-bucket",family:"ui",paths:["M11 4.5l7.5 7.5-6.5 6.5-7.5-7.5z","M10.5 5L8 2.5","M5 11h13.5","M20.5 15.5c-.5 1-1.5 2-1.5 3a1.5 1.5 0 0 0 3 0c0-1-1-2-1.5-3z"],fills:[],accents:["M5 11h13.5l-6.5 7.5z","M20.5 15.5c-.5 1-1.5 2-1.5 3a1.5 1.5 0 0 0 3 0c0-1-1-2-1.5-3z"]},Dp={name:"paintbrush",family:"ui",paths:["M20.5 3.5l-7.5 7.5","M11.5 9.5l3 3","M11 12.5c-3 0-4.5 2-4.5 4.5 0 1.5-1 2.5-2.5 3 1 .5 2 .5 3.5 .5 3 0 5-1.5 5-4.5 0-1-.5-2.5-1.5-3.5z"],fills:[],accents:["M11 12.5c-3 0-4.5 2-4.5 4.5 0 1.5-1 2.5-2.5 3 1 .5 2 .5 3.5 .5 3 0 5-1.5 5-4.5 0-1-.5-2.5-1.5-3.5z"]},Hp={name:"palette",family:"ui",paths:["M12 3a9 9 0 0 0 0 18c1.5 0 2-1 2-2s-.5-1.5-.5-2.5a1.5 1.5 0 0 1 1.5-1.5h2a4 4 0 0 0 4-4c0-4.5-4-8-9-8z"],fills:["M6.25 11a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M8.25 7a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M13.25 7a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:["M12 3a9 9 0 0 0 0 18c1.5 0 2-1 2-2s-.5-1.5-.5-2.5a1.5 1.5 0 0 1 1.5-1.5h2a4 4 0 0 0 4-4c0-4.5-4-8-9-8z"]},_p={name:"panel-bottom",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 15h18"],fills:[],accents:[]},vS={name:"panel-left",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M9 3v18"],fills:[],accents:[]},pS={name:"panel-left-close",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M9 3v18","m16 15-3-3 3-3"],fills:[],accents:[]},yS={name:"panel-left-open",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M9 3v18","m14 9 3 3-3 3"],fills:[],accents:[]},gS={name:"panel-right",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M15 3v18"],fills:[],accents:[]},Up={name:"panel-top",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9h18"],fills:[],accents:[]},MS={name:"panels-top-left",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9h18","M9 21V9"],fills:[],accents:[]},bS={name:"paperclip",family:"ui",paths:["m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551"],fills:[],accents:[]},Bp={name:"parallelogram",family:"tool",paths:["M7 5h14l-4 14H3z"],fills:[],accents:[]},Vp={name:"pause",family:"ui",paths:["M15 3h3a1 1 0 0 1 1 1v16a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-16a1 1 0 0 1 1 -1z","M6 3h3a1 1 0 0 1 1 1v16a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-16a1 1 0 0 1 1 -1z"],fills:[],accents:[]},wS={name:"pen",family:"ui",paths:["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"],fills:[],accents:[]},qp={name:"pen-line",family:"ui",paths:["M13 21h8","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"],fills:[],accents:[]},Gp={name:"pen-tool",family:"ui",paths:["m18 13-.654-4.736a4 4 0 00-2.756-3.266l-9.163-2.9a2 2 0 00-2.017.493l-.82.819a2 2 0 00-.492 2.017l2.9 9.163a4 4 0 003.266 2.756L13 18","M18.648 12.352a1.205 1.205 0 011.704 0l1.296 1.296a1.205 1.205 0 010 1.704l-6.296 6.296a1.205 1.205 0 01-1.704 0l-1.296-1.296a1.205 1.205 0 010-1.704z","m3 3 6.586 6.586","M9 11a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:["M18 13l-.654-4.736a4 4 0 0 0-2.756-3.266l-9.163-2.9a2 2 0 0 0-2.017.493l-.82.819a2 2 0 0 0-.492 2.017l2.9 9.163a4 4 0 0 0 3.266 2.756L13 18z"]},Yp={name:"pencil",family:"ui",paths:["M15.5 4.5l4 4L9 19l-5 1 1-5z","M13 7l4 4"],fills:[],accents:["M15.5 4.5l4 4L9 19l-5 1 1-5z"]},$p={name:"pencil-line",family:"ui",paths:["M13 21h8","m15 5 4 4","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"],fills:[],accents:[]},SS={name:"pentagon",family:"ui",paths:["M10.83 2.38a2 2 0 0 1 2.34 0l8 5.74a2 2 0 0 1 .73 2.25l-3.04 9.26a2 2 0 0 1-1.9 1.37H7.04a2 2 0 0 1-1.9-1.37L2.1 10.37a2 2 0 0 1 .73-2.25z"],fills:[],accents:["M10.83 2.38a2 2 0 0 1 2.34 0l8 5.74a2 2 0 0 1 .73 2.25l-3.04 9.26a2 2 0 0 1-1.9 1.37H7.04a2 2 0 0 1-1.9-1.37L2.1 10.37a2 2 0 0 1 .73-2.25z"]},zS={name:"percent",family:"ui",paths:["M19 5L5 19","M4 6.5a2.5 2.5 0 1 0 5 0a2.5 2.5 0 1 0 -5 0z","M15 17.5a2.5 2.5 0 1 0 5 0a2.5 2.5 0 1 0 -5 0z"],fills:[],accents:[]},Xp={name:"pilcrow",family:"ui",paths:["M13 4v16","M17 4v16","M19 4H9.5a4.5 4.5 0 0 0 0 9H13"],fills:[],accents:[]},xS={name:"pill",family:"ui",paths:["m10.5 20.5 10-10a4.95 4.95 0 1 0-7-7l-10 10a4.95 4.95 0 1 0 7 7Z","m8.5 8.5 7 7"],fills:[],accents:["M10.5 20.5l10-10a4.95 4.95 0 1 0-7-7l-10 10a4.95 4.95 0 1 0 7 7Z"]},CS={name:"pin",family:"ui",paths:["M12 17v5","M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z"],fills:[],accents:[]},ES={name:"pin-off",family:"ui",paths:["M12 17v5","M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89","m2 2 20 20","M9 9v1.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h11"],fills:[],accents:[]},Kp={name:"pipette",family:"ui",paths:["m12 9-8.414 8.414A2 2 0 0 0 3 18.828v1.344a2 2 0 0 1-.586 1.414A2 2 0 0 1 3.828 21h1.344a2 2 0 0 0 1.414-.586L15 12","m18 9 .4.4a1 1 0 1 1-3 3l-3.8-3.8a1 1 0 1 1 3-3l.4.4 3.4-3.4a1 1 0 1 1 3 3z","m2 22 .414-.414"],fills:[],accents:["M12 9l-8.414 8.414A2 2 0 0 0 3 18.828v1.344a2 2 0 0 1-.586 1.414A2 2 0 0 1 3.828 21h1.344a2 2 0 0 0 1.414-.586L15 12z"]},Ip={name:"play",family:"ui",paths:["M7 4.5v15l12-7.5z"],fills:[],accents:[]},Zp={name:"plus",family:"ui",paths:["M12 4.5v15","M4.5 12h15"],fills:[],accents:[]},TS={name:"pointer",family:"ui",paths:["M22 14a8 8 0 0 1-8 8","M18 11v-1a2 2 0 0 0-2-2a2 2 0 0 0-2 2","M14 10V9a2 2 0 0 0-2-2a2 2 0 0 0-2 2v1","M10 9.5V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v10","M18 11a2 2 0 1 1 4 0v3a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15"],fills:[],accents:[]},kS={name:"polar-tracking",family:"tool",paths:["M4 20h16","M4 20 17 7.5","M4 20 11 4","M12 20a8 8 0 0 0 -1.5-4.6"],fills:["M2.75 20a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:[]},AS={name:"polyline",family:"tool",paths:["M4 18l5-9 5 6 6-10"],fills:["M2.75 18a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M7.75 9a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M12.75 15a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z","M18.75 5a1.25 1.25 0 1 0 2.5 0a1.25 1.25 0 1 0 -2.5 0z"],accents:[]},jS={name:"power",family:"ui",paths:["M12 2v10","M18.4 6.6a9 9 0 1 1-12.77.04"],fills:[],accents:[]},NS={name:"presentation",family:"ui",paths:["M2 3h20","M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3","m7 21 5-5 5 5"],fills:[],accents:[]},Fp={name:"printer",family:"ui",paths:["M6 18H4a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2h-2","M6 9V3a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v6","M7 14h10a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-10a1 1 0 0 1 -1 -1v-6a1 1 0 0 1 1 -1z"],fills:[],accents:[]},OS={name:"puzzle",family:"ui",paths:["M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z"],fills:[],accents:[]},Qp={name:"qr-code",family:"ui",paths:["M4 3h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M17 3h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M4 16h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z","M21 16h-3a2 2 0 0 0-2 2v3","M21 21v.01","M12 7v3a2 2 0 0 1-2 2H7","M3 12h.01","M12 3h.01","M12 16v.01","M16 12h1","M21 12v.01","M12 21v-1"],fills:[],accents:[]},RS={name:"quote",family:"ui",paths:["M16 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z","M5 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z"],fills:[],accents:[]},LS={name:"radar",family:"ui",paths:["M19.07 4.93A10 10 0 0 0 6.99 3.34","M4 6h.01","M2.29 9.62A10 10 0 1 0 21.31 8.35","M16.24 7.76A6 6 0 1 0 8.23 16.67","M12 18h.01","M17.99 11.66A6 6 0 0 1 15.77 16.67","M10 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","m13.41 10.59 5.66-5.66"],fills:[],accents:[]},Jp={name:"radius",family:"ui",paths:["M20.34 17.52a10 10 0 1 0-2.82 2.82","M17 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","m13.41 13.41 4.18 4.18","M10 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},Pp={name:"rainbow",family:"ui",paths:["M22 17a10 10 0 0 0-20 0","M6 17a6 6 0 0 1 12 0","M10 17a2 2 0 0 1 4 0"],fills:[],accents:[]},DS={name:"ratio",family:"ui",paths:["M8 2h8a2 2 0 0 1 2 2v16a2 2 0 0 1 -2 2h-8a2 2 0 0 1 -2 -2v-16a2 2 0 0 1 2 -2z","M4 6h16a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"],fills:[],accents:[]},HS={name:"ray",family:"tool",paths:["M5 19 19 5","M14 5h5v5"],fills:["M3.5 19a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z"],accents:[]},_S={name:"receipt",family:"ui",paths:["M12 17V7","M16 8h-6a2 2 0 0 0 0 4h4a2 2 0 0 1 0 4H8","M4 3a1 1 0 0 1 1-1 1.3 1.3 0 0 1 .7.2l.933.6a1.3 1.3 0 0 0 1.4 0l.934-.6a1.3 1.3 0 0 1 1.4 0l.933.6a1.3 1.3 0 0 0 1.4 0l.933-.6a1.3 1.3 0 0 1 1.4 0l.934.6a1.3 1.3 0 0 0 1.4 0l.933-.6A1.3 1.3 0 0 1 19 2a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1 1.3 1.3 0 0 1-.7-.2l-.933-.6a1.3 1.3 0 0 0-1.4 0l-.934.6a1.3 1.3 0 0 1-1.4 0l-.933-.6a1.3 1.3 0 0 0-1.4 0l-.933.6a1.3 1.3 0 0 1-1.4 0l-.934-.6a1.3 1.3 0 0 0-1.4 0l-.933.6a1.3 1.3 0 0 1-.7.2 1 1 0 0 1-1-1z"],fills:[],accents:[]},Wp={name:"rectangle-horizontal",family:"ui",paths:["M4 6h16a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"],fills:[],accents:["M4 6h16a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2z"]},US={name:"rectangle-vertical",family:"ui",paths:["M8 2h8a2 2 0 0 1 2 2v16a2 2 0 0 1 -2 2h-8a2 2 0 0 1 -2 -2v-16a2 2 0 0 1 2 -2z"],fills:[],accents:[]},ey={name:"redo-2",family:"ui",paths:["m15 14 5-5-5-5","M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13"],fills:[],accents:[]},BS={name:"refresh-ccw",family:"ui",paths:["M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8","M3 3v5h5","M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16","M16 16h5v5"],fills:[],accents:[]},ay={name:"refresh-cw",family:"ui",paths:["M4.5 12A7.5 7.5 0 0 1 18 7.5","M18 3v4.5h-4.5","M19.5 12A7.5 7.5 0 0 1 6 16.5","M6 21v-4.5h4.5"],fills:[],accents:[]},VS={name:"region",family:"tool",paths:["M5 8.5 12 4.5l7 4v7l-7 4-7-4z"],fills:[],accents:["M5 8.5 12 4.5l7 4v7l-7 4-7-4z"]},qS={name:"remove-formatting",family:"ui",paths:["M4 7V4h16v3","M5 20h6","M13 4 8 20","m15 15 5 5","m20 15-5 5"],fills:[],accents:[]},ty={name:"repeat",family:"ui",paths:["m17 2 4 4-4 4","M3 11v-1a4 4 0 0 1 4-4h14","m7 22-4-4 4-4","M21 13v1a4 4 0 0 1-4 4H3"],fills:[],accents:[]},ny={name:"replace",family:"ui",paths:["M14 4a1 1 0 0 1 1-1","M15 10a1 1 0 0 1-1-1","M21 4a1 1 0 0 0-1-1","M21 9a1 1 0 0 1-1 1","m3 7 3 3 3-3","M6 10V5a2 2 0 0 1 2-2h2","M4 14h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z"],fills:[],accents:[]},GS={name:"revision-cloud",family:"tool",paths:["M6 8.5a2 2 0 0 1 3.5-1.5 2 2 0 0 1 3.5 0 2 2 0 0 1 3.5 0 2 2 0 0 1 2.5 3 2 2 0 0 1 0 4 2 2 0 0 1 -2.5 3 2 2 0 0 1 -3.5 0 2 2 0 0 1 -3.5 0 2 2 0 0 1 -3.5-1.5 2 2 0 0 1 -1-3.5 2 2 0 0 1 1-3.5z"],fills:[],accents:["M6 8.5a2 2 0 0 1 3.5-1.5 2 2 0 0 1 3.5 0 2 2 0 0 1 3.5 0 2 2 0 0 1 2.5 3 2 2 0 0 1 0 4 2 2 0 0 1 -2.5 3 2 2 0 0 1 -3.5 0 2 2 0 0 1 -3.5 0 2 2 0 0 1 -3.5-1.5 2 2 0 0 1 -1-3.5 2 2 0 0 1 1-3.5z"]},YS={name:"rocket",family:"ui",paths:["M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5","M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09","M9 12a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.4 22.4 0 0 1-4 2z","M9 12H4s.55-3.03 2-4c1.62-1.08 5 .05 5 .05"],fills:[],accents:[]},$S={name:"rotate-3d",family:"ui",paths:["m15.194 13.707 3.814 1.86-1.86 3.814","M16.47214 7.52786 A 5 10 0 1 0 13 21.79796","M21.79796 11 A 10 5 0 1 0 19 15.57071"],fills:[],accents:[]},ly={name:"rotate-ccw",family:"ui",paths:["M4.5 12A7.5 7.5 0 1 0 6 7.5","M6 3v4.5h4.5"],fills:[],accents:[]},XS={name:"rotate-ccw-clock",family:"ui",paths:["M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8","M3 3v5h5","M12 7v5l4 2"],fills:[],accents:[]},iy={name:"rotate-cw",family:"ui",paths:["M19.5 12A7.5 7.5 0 1 1 18 7.5","M18 3v4.5h-4.5"],fills:[],accents:[]},KS={name:"rows-2",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 12h18"],fills:[],accents:[]},sy={name:"rows-3",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M21 9H3","M21 15H3"],fills:[],accents:[]},ry={name:"ruler",family:"ui",paths:["M21.3 15.3a2.4 2.4 0 0 1 0 3.4l-2.6 2.6a2.4 2.4 0 0 1-3.4 0L2.7 8.7a2.41 2.41 0 0 1 0-3.4l2.6-2.6a2.41 2.41 0 0 1 3.4 0Z","m14.5 12.5 2-2","m11.5 9.5 2-2","m8.5 6.5 2-2","m17.5 15.5 2-2"],fills:[],accents:[]},uy={name:"ruler-dimension-line",family:"ui",paths:["M10 15v-3","M14 15v-3","M18 15v-3","M2 8V4","M22 6H2","M22 8V4","M6 15v-3","M4 12h16a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z"],fills:[],accents:[]},cy={name:"save",family:"ui",paths:["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","M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7","M7 3v4a1 1 0 0 0 1 1h7"],fills:[],accents:[]},IS={name:"scale",family:"ui",paths:["M12 3v18","m19 8 3 8a5 5 0 0 1-6 0zV7","M3 7h1a17 17 0 0 0 8-2 17 17 0 0 0 8 2h1","m5 8 3 8a5 5 0 0 1-6 0zV7","M7 21h10"],fills:[],accents:[]},oy={name:"scaling",family:"ui",paths:["M11 3.5H5.5a2 2 0 0 0 -2 2v13a2 2 0 0 0 2 2h13a2 2 0 0 0 2 -2V13","M7.5 12.5h4v4h-4z","M13.5 10.5l6-6","M15 4.5h4.5V9"],fills:[],accents:["M7.5 12.5h4v4h-4z"]},ZS={name:"scan",family:"ui",paths:["M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2"],fills:[],accents:[]},FS={name:"scan-eye",family:"ui",paths:["M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2","M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z","M18.944 12.33a1 1 0 0 0 0-.66 7.5 7.5 0 0 0-13.888 0 1 1 0 0 0 0 .66 7.5 7.5 0 0 0 13.888 0"],fills:[],accents:[]},QS={name:"scan-face",family:"ui",paths:["M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2","M8 14s1.5 2 4 2 4-2 4-2","M9 9h.01","M15 9h.01"],fills:[],accents:[]},JS={name:"scan-search",family:"ui",paths:["M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2","M9 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","m16 16-1.9-1.9"],fills:[],accents:[]},PS={name:"scan-text",family:"ui",paths:["M3 7V5a2 2 0 0 1 2-2h2","M17 3h2a2 2 0 0 1 2 2v2","M21 17v2a2 2 0 0 1-2 2h-2","M7 21H5a2 2 0 0 1-2-2v-2","M7 8h8","M7 12h10","M7 16h6"],fills:[],accents:[]},fy={name:"scissors",family:"ui",paths:["M3.5 6.5a2.5 2.5 0 1 0 5 0a2.5 2.5 0 1 0 -5 0z","M3.5 17.5a2.5 2.5 0 1 0 5 0a2.5 2.5 0 1 0 -5 0z","M8 8l12 10","M8 16L20 6"],fills:[],accents:[]},WS={name:"scroll-text",family:"ui",paths:["M15 12h-5","M15 8h-5","M19 17V5a2 2 0 0 0-2-2H4","M8 21h12a2 2 0 0 0 2-2v-1a1 1 0 0 0-1-1H11a1 1 0 0 0-1 1v1a2 2 0 1 1-4 0V5a2 2 0 1 0-4 0v2a1 1 0 0 0 1 1h3"],fills:[],accents:[]},dy={name:"search",family:"ui",paths:["M4 10.5a6.5 6.5 0 1 0 13 0a6.5 6.5 0 1 0 -13 0z","M15.5 15.5L20 20"],fills:[],accents:[]},ez={name:"search-check",family:"ui",paths:["m8 11 2 2 4-4","M3 11a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","m21 21-4.3-4.3"],fills:[],accents:[]},hy={name:"send",family:"ui",paths:["M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z","m21.854 2.147-10.94 10.939"],fills:[],accents:[]},my={name:"send-to-back",family:"ui",paths:["M16 14h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z","M4 2h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z","M7 14v1a2 2 0 0 0 2 2h1","M14 7h1a2 2 0 0 1 2 2v1"],fills:[],accents:[]},az={name:"separator-horizontal",family:"ui",paths:["m16 16-4 4-4-4","M3 12h18","m8 8 4-4 4 4"],fills:[],accents:[]},vy={name:"settings",family:"ui",paths:["M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915","M9 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},py={name:"settings-2",family:"ui",paths:["M14 17H5","M19 7h-9","M14 17a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M4 7a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z"],fills:[],accents:[]},yy={name:"shapes",family:"ui",paths:["M8.3 10a.7.7 0 0 1-.626-1.079L11.4 3a.7.7 0 0 1 1.198-.043L16.3 8.9a.7.7 0 0 1-.572 1.1Z","M4 14h5a1 1 0 0 1 1 1v5a1 1 0 0 1 -1 1h-5a1 1 0 0 1 -1 -1v-5a1 1 0 0 1 1 -1z","M14 17.5a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0z"],fills:[],accents:["M8.3 10a.7.7 0 0 1-.626-1.079L11.4 3a.7.7 0 0 1 1.198-.043L16.3 8.9a.7.7 0 0 1-.572 1.1Z"]},gy={name:"share-2",family:"ui",paths:["M15 5a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M3 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M15 19a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M8.59 13.51L15.42 17.49","M15.41 6.51L8.59 10.49"],fills:[],accents:[]},My={name:"shell",family:"ui",paths:["M14 11a2 2 0 1 1-4 0 4 4 0 0 1 8 0 6 6 0 0 1-12 0 8 8 0 0 1 16 0 10 10 0 1 1-20 0 11.93 11.93 0 0 1 2.42-7.22 2 2 0 1 1 3.16 2.44"],fills:[],accents:[]},tz={name:"shield-alert",family:"ui",paths:["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","M12 8v4","M12 16h.01"],fills:[],accents:[]},nz={name:"shield-ban",family:"ui",paths:["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","m4.243 5.21 14.39 12.472"],fills:[],accents:[]},by={name:"shield-check",family:"ui",paths:["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","m9 12 2 2 4-4"],fills:[],accents:[]},lz={name:"shrink",family:"ui",paths:["m15 15 6 6m-6-6v4.8m0-4.8h4.8","M9 19.8V15m0 0H4.2M9 15l-6 6","M15 4.2V9m0 0h4.8M15 9l6-6","M9 4.2V9m0 0H4.2M9 9 3 3"],fills:[],accents:[]},wy={name:"sigma",family:"ui",paths:["M18 7V5a1 1 0 0 0-1-1H6.5a.5.5 0 0 0-.4.8l4.5 6a2 2 0 0 1 0 2.4l-4.5 6a.5.5 0 0 0 .4.8H17a1 1 0 0 0 1-1v-2"],fills:[],accents:[]},Sy={name:"signature",family:"ui",paths:["m21 17-2.156-1.868A.5.5 0 0 0 18 15.5v.5a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1c0-2.545-3.991-3.97-8.5-4a1 1 0 0 0 0 5c4.153 0 4.745-11.295 5.708-13.5a2.5 2.5 0 1 1 3.31 3.284","M3 21h18"],fills:[],accents:[]},iz={name:"skip-back",family:"ui",paths:["M17.971 4.285A2 2 0 0 1 21 6v12a2 2 0 0 1-3.029 1.715l-9.997-5.998a2 2 0 0 1-.003-3.432z","M3 20V4"],fills:[],accents:[]},sz={name:"skip-forward",family:"ui",paths:["M21 4v16","M6.029 4.285A2 2 0 0 0 3 6v12a2 2 0 0 0 3.029 1.715l9.997-5.998a2 2 0 0 0 .003-3.432z"],fills:[],accents:[]},rz={name:"slash",family:"ui",paths:["M22 2 2 22"],fills:[],accents:[]},uz={name:"slice",family:"ui",paths:["M11 16.586V19a1 1 0 0 1-1 1H2L18.37 3.63a1 1 0 1 1 3 3l-9.663 9.663a1 1 0 0 1-1.414 0L8 14"],fills:[],accents:[]},zy={name:"sliders-horizontal",family:"ui",paths:["M3.5 6H10","M14 6h6.5","M10 6a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3.5 12h11","M18.5 12h2","M14.5 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3.5 18h2","M9.5 18h11","M5.5 18a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},cz={name:"sliders-vertical",family:"ui",paths:["M10 8h4","M12 21v-9","M12 8V3","M17 16h4","M19 12V3","M19 21v-5","M3 14h4","M5 10V3","M5 21v-7"],fills:[],accents:[]},oz={name:"snowflake",family:"ui",paths:["m10 20-1.25-2.5L6 18","M10 4 8.75 6.5 6 6","m14 20 1.25-2.5L18 18","m14 4 1.25 2.5L18 6","m17 21-3-6h-4","m17 3-3 6 1.5 3","M2 12h6.5L10 9","m20 10-1.5 2 1.5 2","M22 12h-6.5L14 15","m4 10 1.5 2L4 14","m7 21 3-6-1.5-3","m7 3 3 6h4"],fills:[],accents:[]},fz={name:"sparkle",family:"ui",paths:["M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z"],fills:[],accents:["M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z"]},xy={name:"sparkles",family:"ui",paths:["M10 5.5c.5 4.5 3 7 7.5 7.5-4.5 .5-7 3-7.5 7.5-.5-4.5-3-7-7.5-7.5 4.5-.5 7-3 7.5-7.5z","M18.5 3v4","M16.5 5h4"],fills:[],accents:["M10 5.5c.5 4.5 3 7 7.5 7.5-4.5 .5-7 3-7.5 7.5-.5-4.5-3-7-7.5-7.5 4.5-.5 7-3 7.5-7.5z"]},Cy={name:"spell-check",family:"ui",paths:["m20 15-5.5 5.5L12 18","m4 16 6-12 5.115 10.23","M6 12h8"],fills:[],accents:[]},Ey={name:"spline",family:"ui",paths:["M3 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M17 5a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M6.5 17.5C8 11 16 13 17.5 6.5"],fills:[],accents:[]},dz={name:"spline-pointer",family:"ui",paths:["M12.034 12.681a.498.498 0 0 1 .647-.647l9 3.5a.5.5 0 0 1-.033.943l-3.444 1.068a1 1 0 0 0-.66.66l-1.067 3.443a.5.5 0 0 1-.943.033z","M5 17A12 12 0 0 1 17 5","M17 5a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},Ty={name:"split",family:"ui",paths:["M16 3h5v5","M8 3H3v5","M12 22v-8.3a4 4 0 0 0-1.172-2.872L3 3","m15 9 6-6"],fills:[],accents:[]},ky={name:"square",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"]},hz={name:"square-check",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","m16 9-5.5 5.5L8 12"],fills:[],accents:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"]},Ay={name:"square-check-big",family:"ui",paths:["M21 10.656V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.344","m9 11 3 3L22 4"],fills:[],accents:[]},jy={name:"square-dashed",family:"ui",paths:["M3 5a2 2 0 0 1 2 -2","M19 3a2 2 0 0 1 2 2","M21 19a2 2 0 0 1 -2 2","M5 21a2 2 0 0 1 -2 -2","M8.5 3h2","M13.5 3h2","M8.5 21h2","M13.5 21h2","M3 8.5v2","M3 13.5v2","M21 8.5v2","M21 13.5v2"],fills:[],accents:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"]},mz={name:"square-dashed-mouse-pointer",family:"ui",paths:["M12.034 12.681a.498.498 0 0 1 .647-.647l9 3.5a.5.5 0 0 1-.033.943l-3.444 1.068a1 1 0 0 0-.66.66l-1.067 3.443a.5.5 0 0 1-.943.033z","M5 3a2 2 0 0 0-2 2","M19 3a2 2 0 0 1 2 2","M5 21a2 2 0 0 1-2-2","M9 3h1","M9 21h2","M14 3h1","M3 9v1","M21 9v2","M3 14v1"],fills:[],accents:["M5 3h14a2 2 0 0 1 2 2v6.5l-8.32-3.24a.5.5 0 0 0-.65.65L15.31 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"]},vz={name:"square-dot",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M11 12a1 1 0 1 0 2 0a1 1 0 1 0 -2 0z"],fills:[],accents:[]},Ny={name:"square-function",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M9 17c2 0 2.8-1 2.8-2.8V10c0-2 1-3.3 3.2-3","M9 11.2h5.7"],fills:[],accents:[]},pz={name:"square-kanban",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M8 7v7","M12 7v4","M16 7v9"],fills:[],accents:[]},yz={name:"square-minus",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M8 12h8"],fills:[],accents:[]},gz={name:"square-mouse-pointer",family:"ui",paths:["M12.034 12.681a.498.498 0 0 1 .647-.647l9 3.5a.5.5 0 0 1-.033.943l-3.444 1.068a1 1 0 0 0-.66.66l-1.067 3.443a.5.5 0 0 1-.943.033z","M21 11V5a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h6"],fills:[],accents:["M5 3h14a2 2 0 0 1 2 2v6.5l-8.32-3.24a.5.5 0 0 0-.65.65L15.31 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"]},Mz={name:"square-plus",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M8 12h8","M12 8v8"],fills:[],accents:[]},bz={name:"square-split-horizontal",family:"ui",paths:["M12 2v20","M16 3h3a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-3","M8 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3"],fills:[],accents:[]},wz={name:"square-split-vertical",family:"ui",paths:["M2 12h20","M21 16v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-3","M3 8V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v3"],fills:[],accents:[]},Oy={name:"square-square",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M9 8h6a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1v-6a1 1 0 0 1 1 -1z"],fills:[],accents:[]},Sz={name:"square-stack",family:"ui",paths:["M4 10c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h4c1.1 0 2 .9 2 2","M10 16c-1.1 0-2-.9-2-2v-4c0-1.1.9-2 2-2h4c1.1 0 2 .9 2 2","M16 14h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Ry={name:"square-terminal",family:"ui",paths:["m7 11 2-2-2-2","M11 13h4","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},zz={name:"square-x",family:"ui",paths:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","m15 9-6 6","m9 9 6 6"],fills:[],accents:["M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"]},xz={name:"squares-exclude",family:"ui",paths:["M16 12v2a2 2 0 0 1-2 2H9a1 1 0 0 0-1 1v3a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V10a2 2 0 0 0-2-2h0","M4 16a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v3a1 1 0 0 1-1 1h-5a2 2 0 0 0-2 2v2"],fills:[],accents:[]},Cz={name:"squares-intersect",family:"ui",paths:["M10 22a2 2 0 0 1-2-2","M14 2a2 2 0 0 1 2 2","M16 22h-2","M2 10V8","M2 4a2 2 0 0 1 2-2","M20 8a2 2 0 0 1 2 2","M22 14v2","M22 20a2 2 0 0 1-2 2","M4 16a2 2 0 0 1-2-2","M8 10a2 2 0 0 1 2-2h5a1 1 0 0 1 1 1v5a2 2 0 0 1-2 2H9a1 1 0 0 1-1-1z","M8 2h2"],fills:[],accents:[]},Ez={name:"squares-subtract",family:"ui",paths:["M10 22a2 2 0 0 1-2-2","M16 22h-2","M16 4a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h3a1 1 0 0 0 1-1v-5a2 2 0 0 1 2-2h5a1 1 0 0 0 1-1z","M20 8a2 2 0 0 1 2 2","M22 14v2","M22 20a2 2 0 0 1-2 2"],fills:[],accents:[]},Ly={name:"squares-unite",family:"ui",paths:["M4 16a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v3a1 1 0 0 0 1 1h3a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H10a2 2 0 0 1-2-2v-3a1 1 0 0 0-1-1z"],fills:[],accents:[]},Tz={name:"squircle",family:"ui",paths:["M12 3c7.2 0 9 1.8 9 9s-1.8 9-9 9-9-1.8-9-9 1.8-9 9-9"],fills:[],accents:[]},kz={name:"stamp",family:"ui",paths:["M14 13V8.5C14 7 15 7 15 5a3 3 0 0 0-6 0c0 2 1 2 1 3.5V13","M20 15.5a2.5 2.5 0 0 0-2.5-2.5h-11A2.5 2.5 0 0 0 4 15.5V17a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1z","M5 22h14"],fills:[],accents:["M20 15.5a2.5 2.5 0 0 0-2.5-2.5h-11A2.5 2.5 0 0 0 4 15.5V17a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1z"]},Dy={name:"star",family:"ui",paths:["M12 3L14.5 9.5H21L15.5 13.5L17.5 20L12 16.5L6.5 20L8.5 13.5L3 9.5H9.5z"],fills:[],accents:["M12 3L14.5 9.5H21L15.5 13.5L17.5 20L12 16.5L6.5 20L8.5 13.5L3 9.5H9.5z"]},Az={name:"step-back",family:"ui",paths:["M13.971 4.285A2 2 0 0 1 17 6v12a2 2 0 0 1-3.029 1.715l-9.997-5.998a2 2 0 0 1-.003-3.432z","M21 20V4"],fills:[],accents:[]},Hy={name:"step-forward",family:"ui",paths:["M10.029 4.285A2 2 0 0 0 7 6v12a2 2 0 0 0 3.029 1.715l9.997-5.998a2 2 0 0 0 .003-3.432z","M3 4v16"],fills:[],accents:[]},_y={name:"sticker",family:"ui",paths:["M21 9a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 15 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2z","M15 3v5a1 1 0 0 0 1 1h5","M8 13h.01","M16 13h.01","M10 16s.8 1 2 1c1.3 0 2-1 2-1"],fills:[],accents:[]},Uy={name:"sticky-note",family:"ui",paths:["M21 9a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 15 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2z","M15 3v5a1 1 0 0 0 1 1h5"],fills:[],accents:["M21 9a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 15 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2z"]},jz={name:"stretch",family:"tool",paths:["M12 6H6a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h6","M12 12h8","m17 9 3 3-3 3"],fills:[],accents:["M12 6H6a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h6z"]},Nz={name:"stretch-horizontal",family:"ui",paths:["M4 4h16a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z","M4 14h16a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-16a2 2 0 0 1 -2 -2v-2a2 2 0 0 1 2 -2z"],fills:[],accents:[]},By={name:"strikethrough",family:"ui",paths:["M16 4H9a3 3 0 0 0-2.83 4","M14 12a4 4 0 0 1 0 8H6","M4 12L20 12"],fills:[],accents:[]},Vy={name:"subscript",family:"ui",paths:["m4 5 8 8","m12 5-8 8","M20 19h-4c0-1.5.44-2 1.5-2.5S20 15.33 20 14c0-.47-.17-.93-.48-1.29a2.11 2.11 0 0 0-2.62-.44c-.42.24-.74.62-.9 1.07"],fills:[],accents:[]},qy={name:"sun",family:"ui",paths:["M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M12 2v2","M12 20v2","m4.93 4.93 1.41 1.41","m17.66 17.66 1.41 1.41","M2 12h2","M20 12h2","m6.34 17.66-1.41 1.41","m19.07 4.93-1.41 1.41"],fills:[],accents:[]},Gy={name:"sun-dim",family:"ui",paths:["M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M12 4h.01","M20 12h.01","M12 20h.01","M4 12h.01","M17.657 6.343h.01","M17.657 17.657h.01","M6.343 17.657h.01","M6.343 6.343h.01"],fills:[],accents:[]},Oz={name:"sun-medium",family:"ui",paths:["M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M12 3v1","M12 20v1","M3 12h1","M20 12h1","m18.364 5.636-.707.707","m6.343 17.657-.707.707","m5.636 5.636.707.707","m17.657 17.657.707.707"],fills:[],accents:[]},Rz={name:"sun-moon",family:"ui",paths:["M12 2v2","M14.837 16.385a6 6 0 1 1-7.223-7.222c.624-.147.97.66.715 1.248a4 4 0 0 0 5.26 5.259c.589-.255 1.396.09 1.248.715","M16 12a4 4 0 0 0-4-4","m19 5-1.256 1.256","M20 12h2"],fills:[],accents:[]},Lz={name:"sun-snow",family:"ui",paths:["M10 21v-1","M10 4V3","M10 9a3 3 0 0 0 0 6","m14 20 1.25-2.5L18 18","m14 4 1.25 2.5L18 6","m17 21-3-6 1.5-3H22","m17 3-3 6 1.5 3","M2 12h1","m20 10-1.5 2 1.5 2","m3.64 18.36.7-.7","m4.34 6.34-.7-.7"],fills:[],accents:[]},Dz={name:"sunrise",family:"ui",paths:["M12 2v8","m4.93 10.93 1.41 1.41","M2 18h2","M20 18h2","m19.07 10.93-1.41 1.41","M22 22H2","m8 6 4-4 4 4","M16 18a4 4 0 0 0-8 0"],fills:[],accents:[]},Yy={name:"superscript",family:"ui",paths:["m4 19 8-8","m12 19-8-8","M20 12h-4c0-1.5.442-2 1.5-2.5S20 8.334 20 7.002c0-.472-.17-.93-.484-1.29a2.105 2.105 0 0 0-2.617-.436c-.42.239-.738.614-.899 1.06"],fills:[],accents:[]},$y={name:"swatch-book",family:"ui",paths:["M11 17a4 4 0 0 1-8 0V5a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2Z","M16.7 13H19a2 2 0 0 1 2 2v4a2 2 0 0 1-2 2H7","M 7 17h.01","m11 8 2.3-2.3a2.4 2.4 0 0 1 3.404.004L18.6 7.6a2.4 2.4 0 0 1 .026 3.434L9.9 19.8"],fills:[],accents:[]},Xy={name:"table",family:"ui",paths:["M12 3v18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M3 9h18","M3 15h18"],fills:[],accents:[]},Hz={name:"table-2",family:"ui",paths:["M3 9h18","M9 3v18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},_z={name:"table-cells-merge",family:"ui",paths:["M12 21v-6","M12 9V3","M3 15h18","M3 9h18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Uz={name:"table-cells-split",family:"ui",paths:["M12 15V9","M3 15h18","M3 9h18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Ky={name:"table-properties",family:"ui",paths:["M15 3v18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z","M21 9H3","M21 15H3"],fills:[],accents:[]},Iy={name:"tag",family:"ui",paths:["M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z"],fills:["M7 7.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z"],accents:[]},Bz={name:"tags",family:"ui",paths:["M13.172 2a2 2 0 0 1 1.414.586l6.71 6.71a2.4 2.4 0 0 1 0 3.408l-4.592 4.592a2.4 2.4 0 0 1-3.408 0l-6.71-6.71A2 2 0 0 1 6 9.172V3a1 1 0 0 1 1-1z","M2 7v6.172a2 2 0 0 0 .586 1.414l6.71 6.71a2.4 2.4 0 0 0 3.191.193"],fills:["M10 6.5a0.5 0.5 0 1 0 1 0a0.5 0.5 0 1 0 -1 0z"],accents:[]},Vz={name:"target",family:"ui",paths:["M2 12a10 10 0 1 0 20 0a10 10 0 1 0 -20 0z","M6 12a6 6 0 1 0 12 0a6 6 0 1 0 -12 0z","M10 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:[]},qz={name:"terminal",family:"ui",paths:["M12 19h8","m4 17 6-6-6-6"],fills:[],accents:[]},Zy={name:"text-align-center",family:"ui",paths:["M3.5 6h17","M6.5 10h11","M3.5 14h17","M6.5 18h11"],fills:[],accents:[]},Fy={name:"text-align-end",family:"ui",paths:["M3.5 6h17","M9.5 10h11","M3.5 14h17","M9.5 18h11"],fills:[],accents:[]},Qy={name:"text-align-justify",family:"ui",paths:["M3.5 6h17","M3.5 10h17","M3.5 14h17","M3.5 18h17"],fills:[],accents:[]},Jy={name:"text-align-start",family:"ui",paths:["M3.5 6h17","M3.5 10h11","M3.5 14h17","M3.5 18h11"],fills:[],accents:[]},Py={name:"text-cursor",family:"ui",paths:["M17 22h-1a4 4 0 0 1-4-4V6a4 4 0 0 1 4-4h1","M7 22h1a4 4 0 0 0 4-4","M7 2h1a4 4 0 0 1 4 4"],fills:[],accents:[]},Wy={name:"text-cursor-input",family:"ui",paths:["M14 7h5a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-5","M8 17H5a2 2 0 0 1 -2 -2V9a2 2 0 0 1 2 -2h3","M11 4v16","M9 4h4","M9 20h4"],fills:[],accents:[]},Gz={name:"text-justify-center",family:"ui",paths:["M3.5 6h17","M3.5 10h17","M3.5 14h17","M7.5 18h9"],fills:[],accents:[]},Yz={name:"text-justify-end",family:"ui",paths:["M3.5 6h17","M3.5 10h17","M3.5 14h17","M11.5 18h9"],fills:[],accents:[]},$z={name:"text-justify-start",family:"ui",paths:["M3.5 6h17","M3.5 10h17","M3.5 14h17","M3.5 18h9"],fills:[],accents:[]},Xz={name:"text-wrap",family:"ui",paths:["m16 16-3 3 3 3","M3 12h14.5a1 1 0 0 1 0 7H13","M3 19h6","M3 5h18"],fills:[],accents:[]},Kz={name:"thermometer",family:"ui",paths:["M14 4v10.54a4 4 0 1 1-4 0V4a2 2 0 0 1 4 0Z"],fills:[],accents:[]},Iz={name:"thumbs-up",family:"ui",paths:["M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z","M7 10v12"],fills:[],accents:[]},Zz={name:"ticket",family:"ui",paths:["M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z","M13 5v2","M13 17v2","M13 11v2"],fills:[],accents:[]},Fz={name:"timer",family:"ui",paths:["M10 2L14 2","M12 14L15 11","M4 14a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z"],fills:[],accents:[]},e4={name:"toggle-left",family:"ui",paths:["M6 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M9 5h6a7 7 0 0 1 7 7v0a7 7 0 0 1 -7 7h-6a7 7 0 0 1 -7 -7v0a7 7 0 0 1 7 -7z"],fills:[],accents:[]},Qz={name:"tornado",family:"ui",paths:["M21 4H3","M18 8H6","M19 12H9","M16 16h-6","M11 20H9"],fills:[],accents:[]},Jz={name:"transition-cover",family:"tool",paths:["M9 17H4a2 2 0 0 1 -2-2V9a2 2 0 0 1 2-2h5","M22 5H11a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h11","M18.5 12H13","m14.5 10.5-1.5 1.5 1.5 1.5"],fills:[],accents:["M22 5H11a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h11z"]},Pz={name:"transition-curtains",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M6.5 6c.5 5 2 9 5 12","M17.5 6c-.5 5-2 9-5 12"],fills:[],accents:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"]},Wz={name:"transition-cut",family:"tool",paths:["M4 7h5a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z","M15 7h5a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z"],fills:[],accents:["M15 7h5a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-5a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z"]},ex={name:"transition-drape",family:"tool",paths:["M3 8a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v7c-2.5 2.5-5-2-9 0s-6.5 2.5-9 0z"],fills:[],accents:["M3 8a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v7c-2.5 2.5-5-2-9 0s-6.5 2.5-9 0z"]},ax={name:"transition-fade",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M6.5 11.5 9 9","M6.5 15.5l6.5-6.5","M11 15.5l6.5-6.5"],fills:[],accents:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"]},tx={name:"transition-fall-over",family:"tool",paths:["M3 20.5h18","M5 20.5 7.5 15.5h9l2.5 5","M7.5 4.5h.01","M11.5 5h.01","M15 6.5h.01","M17.5 9.5h.01","M18.5 12.5h.01"],fills:[],accents:["M5 20.5 7.5 15.5h9l2.5 5z"]},nx={name:"transition-flash",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M12 8.5v1","M12 14.5v1","M8.5 12h1","M14.5 12h1","m9.5 9.5.7.7","m13.8 13.8.7.7","m14.5 9.5-.7.7","m10.2 13.8-.7.7"],fills:["M10.5 12a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0 -3 0z"],accents:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"]},lx={name:"transition-morph",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M7 12a2.5 2.5 0 1 0 5 0a2.5 2.5 0 1 0 -5 0z","M15 9.5h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z"],fills:[],accents:["M7 12a2.5 2.5 0 1 0 5 0a2.5 2.5 0 1 0 -5 0z","M15 9.5h3a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-3a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1z"]},ix={name:"transition-none",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M8 15.5l8-7"],fills:[],accents:[]},sx={name:"transition-prestige",family:"tool",paths:["M6.5 6h11l3.5 12h-18z"],fills:[],accents:["M6.5 6h11l3.5 12h-18z"]},rx={name:"transition-push",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M12 6v12","M18 12h-3.5","m16 10.5-1.5 1.5 1.5 1.5"],fills:[],accents:["M12 6h7a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-7z"]},ux={name:"transition-random-bars",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M6.5 9.5h6","M6.5 12h10","M6.5 14.5h4"],fills:[],accents:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"]},cx={name:"transition-reveal",family:"tool",paths:["M4.5 4h10a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z","M16.5 10h3a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2-2v-4","M12 11 7.5 6.5","M7.5 10V6.5H11"],fills:[],accents:["M16.5 10h3a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2-2v-4h9z"]},ox={name:"transition-shape",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M8.5 12a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0z"],fills:[],accents:["M8.5 12a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0z"]},fx={name:"transition-split",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M10 6v12","M14 6v12","m7.5 10.5-1.5 1.5 1.5 1.5","m16.5 10.5 1.5 1.5-1.5 1.5"],fills:[],accents:["M10 6h4v12h-4z"]},dx={name:"transition-uncover",family:"tool",paths:["M2 5h11a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2H2","M15 7h5a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-5","M11 12H5.5","m7 10.5-1.5 1.5 1.5 1.5"],fills:[],accents:["M15 7h5a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-5z"]},hx={name:"transition-wind",family:"tool",paths:["M13 7h6a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z","M3 9h5a1.5 1.5 0 1 0 -1.5-1.5","M3 12h6","M3 15h4a1.5 1.5 0 1 1 -1.5 1.5"],fills:[],accents:["M13 7h6a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2v-6a2 2 0 0 1 2 -2z"]},mx={name:"transition-wipe",family:"tool",paths:["M5 6h14a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z","M12 8.5h.01","M12 12h.01","M12 15.5h.01","M14.5 12H18","m16.5 10.5 1.5 1.5-1.5 1.5"],fills:[],accents:["M12 6H5a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h7z"]},a4={name:"trash",family:"ui",paths:["M4 6.5h16","M9 6.5V5a1.5 1.5 0 0 1 1.5 -1.5h3A1.5 1.5 0 0 1 15 5v1.5","M6 6.5l1 12.5a2 2 0 0 0 2 2h6a2 2 0 0 0 2 -2l1-12.5"],fills:[],accents:[]},vx={name:"trending-up",family:"ui",paths:["M16 7h6v6","m22 7-8.5 8.5-5-5L2 17"],fills:[],accents:[]},px={name:"triangle",family:"ui",paths:["M13.73 4a2 2 0 0 0-3.46 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"],fills:[],accents:["M13.73 4a2 2 0 0 0-3.46 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"]},yx={name:"triangle-alert",family:"ui",paths:["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","M12 9v4","M12 17h.01"],fills:[],accents:[]},gx={name:"triangles-centerline-dashed-horizontal",family:"ui",paths:["M10 12H8","M16 12h-2","M22 12h-2","M4 12H2","M7.298 20.288A1 1 0 008 22h8a1 1 0 00.703-1.712l-3.991-3.99a1 1 0 00-1.424-.001z","M7.298 3.712A1 1 0 018 2h8a1 1 0 01.703 1.712l-3.991 3.99a1 1 0 01-1.424.001z"],fills:[],accents:[]},t4={name:"type",family:"ui",paths:["M5 7.5V5h14v2.5","M12 5v14","M9 19h6"],fills:[],accents:[]},Mx={name:"type-outline",family:"ui",paths:["M14 16.5a.5.5 0 0 0 .5.5h.5a2 2 0 0 1 0 4H9a2 2 0 0 1 0-4h.5a.5.5 0 0 0 .5-.5v-9a.5.5 0 0 0-.5-.5h-3a.5.5 0 0 0-.5.5V8a2 2 0 0 1-4 0V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v3a2 2 0 0 1-4 0v-.5a.5.5 0 0 0-.5-.5h-3a.5.5 0 0 0-.5.5Z"],fills:[],accents:[]},n4={name:"underline",family:"ui",paths:["M6 4v6a6 6 0 0 0 12 0V4","M4 20L20 20"],fills:[],accents:[]},l4={name:"undo-2",family:"ui",paths:["M9 14 4 9l5-5","M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11"],fills:[],accents:[]},bx={name:"unfold-horizontal",family:"ui",paths:["M16 12h6","M8 12H2","M12 2v2","M12 8v2","M12 14v2","M12 20v2","m19 15 3-3-3-3","m5 9-3 3 3 3"],fills:[],accents:[]},wx={name:"unfold-vertical",family:"ui",paths:["M12 22v-6","M12 8V2","M4 12H2","M10 12H8","M16 12h-2","M22 12h-2","m15 19-3 3-3-3","m15 5-3-3-3 3"],fills:[],accents:[]},i4={name:"ungroup",family:"ui",paths:["M5 3.5h4a1.5 1.5 0 0 1 1.5 1.5v4a1.5 1.5 0 0 1 -1.5 1.5h-4a1.5 1.5 0 0 1 -1.5 -1.5v-4a1.5 1.5 0 0 1 1.5 -1.5z","M15 13.5h4a1.5 1.5 0 0 1 1.5 1.5v4a1.5 1.5 0 0 1 -1.5 1.5h-4a1.5 1.5 0 0 1 -1.5 -1.5v-4a1.5 1.5 0 0 1 1.5 -1.5z"],fills:[],accents:[]},s4={name:"unlink",family:"ui",paths:["m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71","m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71","M8 2L8 5","M2 8L5 8","M16 19L16 22","M19 16L22 16"],fills:[],accents:[]},r4={name:"upload",family:"ui",paths:["M12 3v12","m17 8-5-5-5 5","M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"],fills:[],accents:[]},Sx={name:"user",family:"ui",paths:["M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2","M8 7a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z"],fills:[],accents:[]},zx={name:"user-minus",family:"ui",paths:["M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2","M5 7a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M22 11L16 11"],fills:[],accents:[]},xx={name:"user-plus",family:"ui",paths:["M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2","M5 7a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z","M19 8L19 14","M22 11L16 11"],fills:[],accents:[]},Cx={name:"user-round",family:"ui",paths:["M7 8a5 5 0 1 0 10 0a5 5 0 1 0 -10 0z","M20 21a8 8 0 0 0-16 0"],fills:[],accents:[]},Ex={name:"users",family:"ui",paths:["M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2","M16 3.128a4 4 0 0 1 0 7.744","M22 21v-2a4 4 0 0 0-3-3.87","M5 7a4 4 0 1 0 8 0a4 4 0 1 0 -8 0z"],fills:[],accents:[]},Tx={name:"variable",family:"ui",paths:["M8 21s-4-3-4-9 4-9 4-9","M16 3s4 3 4 9-4 9-4 9","M15 9L9 15","M9 9L15 15"],fills:[],accents:[]},u4={name:"vector-polygon",family:"ui",paths:["m12.828 4.813 5.344 2.375","m15.769 18.153 3.461-8.306","m5.687 14.074 7.625 4.852","M9.772 5.579 5.228 11.42","M9 4a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M13 20a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M18 8a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M2 13a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:["M11 4l9 4-5 12-11-7z"]},c4={name:"vector-square",family:"ui",paths:["M17.055 4.533a24 24 0 00-10.11 0","M19.467 17.055a24 24 0 000-10.11","M4.533 6.945a24 24 0 000 10.11","M6.945 19.467a24 24 0 0010.11 0","M17 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M17 5a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3 19a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M3 5a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:["M5 5h14v14H5z"]},o4={name:"video",family:"ui",paths:["m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5","M4 6h10a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-8a2 2 0 0 1 2 -2z"],fills:[],accents:[]},f4={name:"volume-2",family:"ui",paths:["M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z","M16 9a5 5 0 0 1 0 6","M19.364 18.364a9 9 0 0 0 0-12.728"],fills:[],accents:[]},kx={name:"wallet-cards",family:"ui",paths:["M3 11h3.75a2 2 0 0 1 1.6.8l.45.6a4 4 0 0 0 6.4 0l.45-.6a2 2 0 0 1 1.6-.8H21","M3 7h18","M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2z"],fills:[],accents:[]},d4={name:"wand-sparkles",family:"ui",paths:["M3.5 20.5L13.5 10.5","M13.5 8.5L16 6l2 2-2.5 2.5z","M19.5 13.5v3","M18 15h3","M8 3.5v3","M6.5 5h3"],fills:[],accents:["M13.5 8.5L16 6l2 2-2.5 2.5z"]},h4={name:"waves-horizontal",family:"ui",paths:["M2 12q2.5 2 5 0t5 0 5 0 5 0","M2 19q2.5 2 5 0t5 0 5 0 5 0","M2 5q2.5 2 5 0t5 0 5 0 5 0"],fills:[],accents:[]},m4={name:"waypoints",family:"ui",paths:["m10.586 5.414-5.172 5.172","m18.586 13.414-5.172 5.172","M6 12h12","M10 20a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M10 4a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M18 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M2 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"],fills:[],accents:["M10 20a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M10 4a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M18 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z","M2 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0z"]},Ax={name:"webhook",family:"ui",paths:["M18 16.98h-5.99c-1.1 0-1.95.94-2.48 1.9A4 4 0 0 1 2 17c.01-.7.2-1.4.57-2","m6 17 3.13-5.78c.53-.97.1-2.18-.5-3.1a4 4 0 1 1 6.89-4.06","m12 6 3.13 5.73C15.66 12.7 16.9 13 18 13a4 4 0 0 1 0 8"],fills:[],accents:[]},v4={name:"whole-word",family:"ui",paths:["M4 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M10 9v6","M14 12a3 3 0 1 0 6 0a3 3 0 1 0 -6 0z","M14 7v8","M22 17v1c0 .5-.5 1-1 1H3c-.5 0-1-.5-1-1v-1"],fills:[],accents:[]},jx={name:"wind",family:"ui",paths:["M12.8 19.6A2 2 0 1 0 14 16H2","M17.5 8a2.5 2.5 0 1 1 2 4H2","M9.8 4.4A2 2 0 1 1 11 8H2"],fills:[],accents:[]},Nx={name:"workflow",family:"ui",paths:["M5 3h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z","M7 11v4a2 2 0 0 0 2 2h4","M15 13h4a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-4a2 2 0 0 1 -2 -2v-4a2 2 0 0 1 2 -2z"],fills:[],accents:[]},Ox={name:"wrench",family:"ui",paths:["M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z"],fills:[],accents:[]},p4={name:"x",family:"ui",paths:["M6 6l12 12","M18 6L6 18"],fills:[],accents:[]},y4={name:"zap",family:"ui",paths:["M15.914 4a1.5 1.5 0 00-2.474-1.561l-9 9A1.5 1.5 0 005.5 14h4.002a.5.5 0 01.471.666L8.086 20a1.5 1.5 0 002.475 1.56l9-9A1.5 1.5 0 0018.5 10h-3.997a.5.5 0 01-.472-.667z"],fills:[],accents:[]},Rx={name:"zap-off",family:"ui",paths:["M10.768 5.111 13.44 2.44a1.5 1.5 0 012.474 1.561l-1.633 4.625","m18.889 13.232.672-.672A1.5 1.5 0 0018.5 10h-2.844","m2 2 20 20","m7.94 7.94-3.5 3.499A1.5 1.5 0 005.5 14h4.002a.5.5 0 01.471.666L8.086 20a1.5 1.5 0 002.475 1.56l5.5-5.5"],fills:[],accents:[]},g4={name:"zoom-in",family:"ui",paths:["M3 11a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M21 21L16.65 16.65","M11 8L11 14","M8 11L14 11"],fills:[],accents:["M3 11a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z"]},Lx={name:"zoom-out",family:"ui",paths:["M3 11a8 8 0 1 0 16 0a8 8 0 1 0 -16 0z","M21 21L16.65 16.65","M8 11L14 11"],fills:[],accents:[]},Dx="var(--kit-icon-accent, var(--kit-primary, currentColor))";function O(l){const s=w.forwardRef(function({size:c=24,color:f="currentColor",strokeWidth:o=b5,absoluteStrokeWidth:d=!1,accent:p,className:y,children:g,...v},b){const M=Number(c);return w.createElement("svg",{ref:b,xmlns:"http://www.w3.org/2000/svg",width:c,height:c,viewBox:"0 0 24 24",fill:"none",stroke:f,strokeWidth:Cb({size:Number.isFinite(M)?M:24,strokeWidth:Number(o),absoluteStrokeWidth:d}),strokeLinecap:"round",strokeLinejoin:"round",className:["tessera-icon",`tessera-icon-${l.name}`,y].filter(Boolean).join(" "),"aria-hidden":v["aria-label"]||v["aria-labelledby"]?void 0:!0,...v},p===!1?null:l.accents.map((z,x)=>w.createElement("path",{key:`accent-${x}`,d:z,className:"tessera-icon-accent",fill:typeof p=="string"?p:Dx,stroke:"none",style:{fillOpacity:p===void 0?`var(--tessera-icon-accent-opacity, ${l.family==="tool"?um:0})`:um}})),l.paths.map((z,x)=>w.createElement("path",{key:x,d:z})),l.fills.map((z,x)=>w.createElement("path",{key:`fill-${x}`,d:z,fill:f})),g)});return s.displayName=`${l.name}Icon`,s}var Hx=O(w5),_x=O(S5),uu=O(z5),Ux=O(x5),Bx=O(C5),Vx=O(E5),qx=O(T5),om=O(k5),Gx=O(A5),Yx=O(j5),cu=O(N5),a0=O(O5),$x=O(R5),ds=O(L5),Xx=O(D5),Kx=O(H5),M4=O(_5),b4=O(U5),Ix=O(B5),t0=O(V5),w4=O(q5),Zx=O(G5),Fx=O(Y5),Qx=O($5),n0=O(X5),ci=O(K5),S4=O(I5),ws=O(Z5),Jx=O(F5),Px=O(Q5),Wx=O(J5),eC=O(P5),aC=O(W5),tC=O(ev),z4=O(av),nC=O(tv),lC=O(nv),iC=O(lv),x4=O(iv),sC=O(sv),rC=O(rv),uC=O(uv),C4=O(cv),cC=O(ov),oC=O(fv),fC=O(dv),di=O(hv),dC=O(mv),hC=O(vv),E4=O(pv),mC=O(yv),fm=O(gv),vC=O(Mv),pC=O(bv),yC=O(wv),E1=O(Sv),gC=O(zv),MC=O(xv),vs=O(Cv),ou=O(Ev),bC=O(Tv),dm=O(kv),l0=O(Av),wC=O(jv),SC=O(Nv),zC=O(Ov),xC=O(Rv),hm=O(Lv),mm=O(Dv),T4=O(Hv),CC=O(_v),k4=O(Uv),vm=O(Bv),EC=O(Vv),ps=O(qv),A4=O(Gv),TC=O(Yv),kC=O($v),AC=O(Xv),T1=O(Kv),ys=O(Iv),j4=O(Zv),N4=O(Fv),jC=O(Qv),NC=O(Jv),k1=O(Pv),O4=O(Wv),OC=O(ep),R4=O(ap),RC=O(tp),LC=O(np),fu=O(lp),A1=O(ip),DC=O(sp),HC=O(rp),oi=O(up),_C=O(cp),UC=O(op),j1=O(fp),BC=O(dp),VC=O(hp),gs=O(mp),N1=O(vp),qC=O(pp),GC=O(yp),YC=O(gp),$C=O(Mp),i0=O(bp),XC=O(wp),KC=O(Sp),IC=O(zp),du=O(xp),L4=O(Cp),D4=O(Ep),ZC=O(Tp),FC=O(kp),QC=O(Ap),JC=O(jp),PC=O(Np),WC=O(Op),H4=O(Rp),_4=O(Lp),eE=O(Dp),U4=O(Hp),aE=O(_p),B4=O(Up),tE=O(Bp),nE=O(Vp),lE=O(qp),V4=O(Gp),Ms=O(Yp),iE=O($p),O1=O(Xp),sE=O(Kp),rE=O(Ip),Dn=O(Zp),s0=O(Fp),uE=O(Qp),cE=O(Jp),oE=O(Pp),fE=O(Wp),q4=O(ey),r0=O(ay),dE=O(ty),G4=O(ny),hE=O(ly),Y4=O(iy),$4=O(sy),Cu=O(ry),mE=O(uy),X4=O(cy),u0=O(oy),c0=O(fy),K4=O(dy),vE=O(hy),I4=O(my),o0=O(vy),Z4=O(py),Eu=O(yy),pE=O(gy),yE=O(My),gE=O(by),ME=O(wy),bE=O(Sy),tu=O(zy),f0=O(xy),wE=O(Cy),d0=O(Ey),SE=O(Ty),Ss=O(ky),zE=O(Ay),R1=O(jy),h0=O(Ny),xE=O(Oy),CE=O(Ry),EE=O(Ly),TE=O(Dy),pm=O(Hy),kE=O(_y),AE=O(Uy),jE=O(By),NE=O(Vy),OE=O(qy),RE=O(Gy),LE=O(Yy),DE=O($y),F4=O(Xy),HE=O(Ky),Q4=O(Iy),_E=O(Zy),UE=O(Fy),BE=O(Qy),VE=O(Jy),qE=O(Py),GE=O(Wy),YE=O(e4),Hn=O(a4),Tu=O(t4),$E=O(n4),m0=O(l4),ku=O(i4),nu=O(s4),XE=O(r4),KE=O(u4),IE=O(c4),J4=O(o4),ZE=O(f4),P4=O(d4),W4=O(h4),eg=O(m4),FE=O(v4),hu=O(p4),QE=O(y4),ag=O(g4),na=1.5,ua=w.forwardRef(function({variant:s,size:u,iconOnly:c,loading:f,className:o,children:d,...p},y){return h.jsxs("button",{ref:y,type:"button",className:v0("kui-button",o),"data-variant":s,"data-size":u,"data-icon-only":c||void 0,"aria-busy":f||void 0,...p,children:[f?h.jsx(tg,{size:16}):null,d]})});function tg({size:l=16,label:s,className:u}){return h.jsx(VC,{className:v0("kui-spinner",u),size:l,strokeWidth:na,role:s?"status":void 0,"aria-label":s,"aria-hidden":s?void 0:!0})}function Ge({icon:l,label:s,pressed:u,className:c,...f}){return h.jsx("button",{type:"button",className:v0("kui-icon-button",c),"aria-label":s,title:s,"aria-pressed":u,...f,children:h.jsx(l,{size:16,strokeWidth:na,"aria-hidden":"true"})})}function v0(...l){return l.filter(Boolean).join(" ")}function JE(l,s,u){const c=l>1,f=l+s<u-1;return c&&f?"both":c?"start":f?"end":"none"}function PE(l,s){const[u,c]=w.useState("none");return w.useLayoutEffect(()=>{const f=l.current;if(!f)return;const o=()=>c(JE(f.scrollLeft,f.clientWidth,f.scrollWidth));o(),f.addEventListener("scroll",o,{passive:!0});let d=null;const p=()=>{if(d){d.disconnect(),d.observe(f);for(const g of f.querySelectorAll(":scope > *, .kui-ribbon-group"))d.observe(g)}};typeof ResizeObserver<"u"&&(d=new ResizeObserver(o)),p();const y=typeof MutationObserver<"u"?new MutationObserver(()=>(p(),o())):null;return y==null||y.observe(f,{childList:!0,subtree:!0}),()=>{f.removeEventListener("scroll",o),d==null||d.disconnect(),y==null||y.disconnect()}},[l,s]),u}function Au({className:l,panelClassName:s,role:u,resetKey:c,labels:f,testId:o,panelRef:d,children:p}){const y=w.useRef(null),g=d??y,v=PE(g,c),b=M=>{const z=g.current;if(!z)return;const x=M*Math.max(80,z.clientWidth*.75);typeof z.scrollBy=="function"?z.scrollBy({left:x,behavior:"smooth"}):z.scrollLeft+=x};return h.jsxs("div",{className:`kui-overflow-strip ${l}`,"data-overflow":v,children:[h.jsx("div",{ref:g,className:`kui-overflow-strip-panel ${s}`,role:u,children:p}),v==="start"||v==="both"?h.jsx("button",{type:"button",className:"kui-ribbon-scroll","data-side":"start","aria-label":f.start,title:f.start,onClick:()=>b(-1),"data-testid":`${o}-start`,children:h.jsx(S4,{size:14,strokeWidth:na,"aria-hidden":"true"})}):null,v==="end"||v==="both"?h.jsx("button",{type:"button",className:"kui-ribbon-scroll","data-side":"end","aria-label":f.end,title:f.end,onClick:()=>b(1),"data-testid":`${o}-end`,children:h.jsx(ws,{size:14,strokeWidth:na,"aria-hidden":"true"})}):null]})}var Ut=w.createContext("full"),ng=w.createContext(l=>`More: ${l}`),zs=Object.freeze({size:"full",icons:new Set,collapsed:new Set}),dl=w.createContext(zs);function L1(l){return l.id??l.label}function lg({id:l,label:s,disabled:u,children:c}){const f=M5();return h.jsx(Ut.Provider,{value:"full",children:h.jsx(dl.Provider,{value:zs,children:h.jsxs("div",{className:"kui-ribbon-group",children:[h.jsx("div",{className:"kui-ribbon-group-body",children:h.jsxs("fieldset",{className:"kui-element",disabled:u,role:"presentation",children:[c,l?f.renderExtras(l,"ribbon"):null]})}),h.jsx("div",{className:"kui-ribbon-group-label",children:s})]})})})}function ig(l){const s=[];for(const u of w.Children.toArray(l)){if(!w.isValidElement(u))continue;if(u.props.primary){s.push(u);continue}const{type:c}=u;if(c!==w.Fragment&&typeof c!="string"&&c!==lu&&c!==aT)continue;const f=ig(u.props.children);f.length&&s.push(c===w.Fragment?h.jsx(w.Fragment,{children:f},u.key):w.cloneElement(u,void 0,f))}return s}function WE({id:l,label:s,icon:u,disabled:c,children:f}){const o=w.useContext(ng),d=w.useRef(null),p=w.useRef(null),[y,g]=w.useState(!0),[v,b]=w.useState(!1),[M,z]=w.useState(null),x=ig(f);w.useLayoutEffect(()=>{var G;if(v)return;const N=x.length>0&&((G=d.current)==null?void 0:G.querySelector("[data-primary], button, input, select, textarea"))!=null;N!==y&&g(N)});const E=l??s,T=()=>{var N;v||z(((N=d.current)==null?void 0:N.getBoundingClientRect().width)??null),b(G=>!G)},C=o(s);return h.jsxs("div",{className:"kui-line-group",role:"group","aria-label":s,"data-kit-ui-id":l,children:[v&&y?h.jsx("div",{className:"kui-line-inline","aria-hidden":"true",style:{width:M??void 0,boxSizing:"border-box",flex:"none"}}):h.jsx("div",{ref:d,className:"kui-line-inline",hidden:!y,children:h.jsx("fieldset",{className:"kui-element",disabled:c,role:"presentation",children:h.jsx(Ut.Provider,{value:"primary",children:x})})}),h.jsxs("span",{ref:p,style:{display:"inline-flex"},children:[y?h.jsx("button",{type:"button",className:"kui-line-more","aria-label":C,title:C,"aria-haspopup":"dialog","aria-expanded":v,onClick:T,"data-testid":`kui-line-more-${E}`,children:h.jsx(ci,{size:12,strokeWidth:na,"aria-hidden":"true"})}):h.jsxs("button",{type:"button",className:"kui-ribbon-button kui-line-collapsed","data-size":"small",title:s,"aria-haspopup":"dialog","aria-expanded":v,onClick:T,"data-testid":`kui-line-group-${E}`,children:[u?h.jsx(u,{size:16,strokeWidth:na,"aria-hidden":"true"}):null,h.jsx("span",{children:s}),h.jsx(ci,{size:12,strokeWidth:na,"aria-hidden":"true"})]}),h.jsx(e0,{open:v,anchor:p,onClose:()=>b(!1),label:s,className:"kui-line-popover",testId:`kui-line-popover-${E}`,children:h.jsx(lg,{id:l,label:s,disabled:c,children:f})})]})]})}function eT({id:l,label:s,icon:u,disabled:c,children:f}){const o=w.useRef(null),[d,p]=w.useState(!1),y=L1({id:l,label:s});return h.jsx("div",{className:"kui-ribbon-group kui-ribbon-group-collapsed",role:"group","aria-label":s,"data-kit-ui-id":l,"data-ribbon-group":y,children:h.jsxs("span",{ref:o,style:{display:"inline-flex"},children:[h.jsxs("button",{type:"button",className:"kui-ribbon-button","data-size":"large",title:s,"aria-haspopup":"dialog","aria-expanded":d,onClick:()=>p(g=>!g),"data-testid":`kui-ribbon-collapsed-${y}`,children:[h.jsxs("span",{style:{display:"inline-flex",alignItems:"center"},children:[u?h.jsx(u,{size:28,strokeWidth:na,"aria-hidden":"true"}):null,h.jsx(ci,{size:12,strokeWidth:na,"aria-hidden":"true"})]}),h.jsx("span",{children:s})]}),h.jsx(e0,{open:d,anchor:o,onClose:()=>p(!1),label:s,className:"kui-line-popover",testId:`kui-ribbon-collapsed-panel-${y}`,children:h.jsx(lg,{id:l,label:s,disabled:c,children:f})})]})})}function Rn({id:l,label:s,icon:u,children:c}){const f=M5(),o=w.useContext(Ut),d=w.useContext(dl);l&&f.drawn(l);const p=l?f.state(l):null;if(p!=null&&p.hidden)return null;if(o==="line")return h.jsx(WE,{id:l,label:s,icon:u,disabled:(p==null?void 0:p.disabled)??!1,children:c});const y=L1({id:l,label:s});return d.collapsed.has(y)?h.jsx(eT,{id:l,label:s,icon:u,disabled:(p==null?void 0:p.disabled)??!1,children:c}):d.icons.has(y)&&d.size!=="icon"?h.jsx(dl.Provider,{value:{...d,size:"icon"},children:h.jsx(Rn,{id:l,label:s,icon:u,children:c})}):h.jsxs("div",{className:"kui-ribbon-group",role:"group","aria-label":s,"data-kit-ui-id":l,"data-ribbon-group":L1({id:l,label:s}),children:[h.jsx("div",{className:"kui-ribbon-group-body",children:h.jsxs("fieldset",{className:"kui-element",disabled:(p==null?void 0:p.disabled)??!1,role:"presentation",children:[c,l?f.renderExtras(l,"ribbon"):null]})}),h.jsx("div",{className:"kui-ribbon-group-label",children:s})]})}function lu({children:l}){const s=w.useContext(Ut)==="primary";return h.jsx("div",{className:s?"kui-line-contents":"kui-ribbon-stack",children:l})}function aT({children:l}){const s=w.useContext(Ut)==="primary";return h.jsx("div",{className:s?"kui-line-contents":"kui-ribbon-row",children:l})}function sg(l,s,u,c,f="full"){return l==="full"?f==="icon"&&u?"icon":f!=="full"&&s==="large"?"small":s:l!=="primary"?s:u&&!c?"icon":s==="large"?"small":s}function St({icon:l,label:s,size:u="small",pressed:c,swatch:f,primary:o,lineLabel:d,...p}){const y=w.useContext(Ut),g=w.useContext(dl);if(y==="primary"&&!o)return null;const v=sg(y,u,l!=null,d,g.size),b=v==="large"?28:16;return h.jsxs("button",{type:"button",className:"kui-ribbon-button","data-size":v,"data-primary":o||void 0,"aria-pressed":c,"aria-label":s,title:s,...p,children:[l?h.jsxs("span",{style:{display:"inline-flex",flexDirection:"column",alignItems:"center"},children:[h.jsx(l,{size:b,strokeWidth:na,"aria-hidden":"true"}),f?h.jsx("span",{style:{width:b,height:3,marginTop:1,borderRadius:1,background:f}}):null]}):null,v==="icon"?null:h.jsx("span",{children:s})]})}var rg=w.createContext(null);function tT(l,s,u){const c=w.useRef({inside:s,close:u});c.current={inside:s,close:u},w.useEffect(()=>{if(!l)return;const f=d=>{c.current.inside.some(p=>{var y;return(y=p.current)==null?void 0:y.contains(d.target)})||c.current.close()},o=d=>{d.key==="Escape"&&c.current.close()};return window.addEventListener("pointerdown",f,!0),window.addEventListener("keydown",o),()=>{window.removeEventListener("pointerdown",f,!0),window.removeEventListener("keydown",o)}},[l])}var ug=l=>[...l.querySelectorAll('[role^="menuitem"]:not(:disabled)')].filter(s=>{var u;return((u=s.parentElement)==null?void 0:u.closest('[role="menu"]'))===l});function cg(l,s){if(l.key==="Escape"&&s){l.preventDefault(),l.stopPropagation(),s();return}const u=ug(l.currentTarget);if(!u.length)return;const c=u.indexOf(document.activeElement),f={ArrowDown:c+1,ArrowUp:c<0?u.length-1:c-1,Home:0,End:u.length-1}[l.key];f!==void 0&&(l.preventDefault(),l.stopPropagation(),u[(f+u.length)%u.length].focus())}function nT(l,s,u,c){const f=w.useRef(c);f.current=c,w.useLayoutEffect(()=>{if(!l)return;const o=f.current();return()=>{var p;const d=document.activeElement;o!=null&&o.isConnected&&(!d||d===document.body||(p=u.current)!=null&&p.contains(d))&&o.focus()}},[u,l]),w.useLayoutEffect(()=>{var o;l&&s&&u.current&&((o=ug(u.current)[0])==null||o.focus())},[u,l,s])}function xs({trigger:l,children:s,align:u="start",placement:c="below"}){const[f,o]=w.useState(!1),d=w.useRef(null),p=w.useRef(null),[y,g]=w.useState(null),v=w.useCallback(()=>o(!1),[]),b=w.useCallback(()=>{var G,J;if(!d.current)return;const M=d.current.getBoundingClientRect(),z=((G=p.current)==null?void 0:G.offsetWidth)??200,x=u==="end"?M.right-z:M.left,E=M.bottom+4,T=((J=p.current)==null?void 0:J.offsetHeight)??0,C=M.top-4-8,N=Math.max(4,Math.min(x,window.innerWidth-z-4));if(c==="auto"&&E+T>window.innerHeight-8&&C>window.innerHeight-E-8){const $=Math.max(0,C);g({left:N,top:M.top-4-Math.min(T,$),maxHeight:$});return}g({left:N,top:E,maxHeight:Math.max(0,window.innerHeight-E-8)})},[u,c]);return w.useLayoutEffect(()=>{if(!f){g(null);return}return b(),window.addEventListener("resize",b),()=>window.removeEventListener("resize",b)},[f,b]),tT(f,[p,d],v),nT(f,y!=null,p,()=>{var M;return((M=d.current)==null?void 0:M.querySelector("button, [tabindex]"))??null}),h.jsxs("span",{ref:d,style:{display:"inline-flex"},children:[l({open:f,toggle:()=>o(M=>!M)}),f?h.jsx("div",{ref:p,className:"kui-popover",role:"menu",style:y?{left:y.left,top:y.top,maxHeight:y.maxHeight}:{visibility:"hidden"},onKeyDown:M=>cg(M,v),onClick:M=>{M.target.closest("button")&&o(!1)},children:h.jsx(rg.Provider,{value:{close:v},children:s})}):null]})}function Bt({icon:l,label:s,shortcut:u,onSelect:c,disabled:f,checked:o,testId:d,uiId:p}){const y=w.useContext(rg);return h.jsxs("button",{type:"button",role:o===void 0?"menuitem":"menuitemcheckbox","aria-checked":o,className:"kui-menu-item",disabled:f,"data-testid":d,"data-kit-ui-id":p,onClick:()=>{y==null||y.close(),c()},children:[o?h.jsx(n0,{size:15,strokeWidth:na,"aria-hidden":"true"}):l?h.jsx(l,{size:15,strokeWidth:na,"aria-hidden":"true"}):h.jsx("span",{style:{width:15}}),h.jsx("span",{children:s}),u?h.jsx("kbd",{children:u}):null]})}function og(){return h.jsx("div",{className:"kui-menu-separator",role:"separator"})}function lT({children:l,onClick:s}){return h.jsx("footer",{className:"kui-status-bar",onClick:s,children:l})}function iT(){return h.jsx("div",{className:"kui-status-spacer"})}function sT({zoom:l,onZoom:s,onFit:u,min:c=.1,max:f=4,labels:o}){const d=y=>Math.log(y/c)/Math.log(f/c),p=y=>c*Math.pow(f/c,y);return h.jsxs("div",{className:"kui-zoom",children:[h.jsx("button",{type:"button",className:"kui-icon-button","aria-label":o.out,title:o.out,onClick:()=>s(l/1.25),children:"−"}),h.jsx("input",{type:"range",min:0,max:1,step:.001,value:d(l),onChange:y=>s(p(Number(y.target.value))),"aria-label":o.fit}),h.jsx("button",{type:"button",className:"kui-icon-button","aria-label":o.in,title:o.in,onClick:()=>s(l*1.25),children:"+"}),h.jsxs("span",{className:"kui-zoom-value","data-testid":"kit-zoom",children:[Math.round(l*100),"%"]}),h.jsx("button",{type:"button",className:"kui-button","data-variant":"ghost",onClick:u,children:o.fit})]})}function Un({title:l,children:s,actions:u,onClose:c,onEscape:f,modal:o=!0,uiId:d,testId:p,position:y,onMove:g}){const v=w.useRef(null);w.useEffect(()=>{const C=N=>{var G;if(N.key==="Escape"){if(!o){const J=document.activeElement;if(J&&J!==document.body&&!((G=v.current)!=null&&G.contains(J)))return}f?f(N):c()}};return window.addEventListener("keydown",C),()=>window.removeEventListener("keydown",C)},[c,f,o]);const b=w.useRef(null),[M,z]=w.useState(null);w.useEffect(()=>{z(null)},[y==null?void 0:y.x,y==null?void 0:y.y]);const x=M??y??null,E=(C,N)=>({x:Math.round(Math.min(Math.max(0,C),Math.max(0,window.innerWidth-48))),y:Math.round(Math.min(Math.max(0,N),Math.max(0,window.innerHeight-32)))}),T=g?{"data-movable":"true",onPointerDown:C=>{var J,$,le;if(C.button!==0)return;const N=(J=v.current)==null?void 0:J.getBoundingClientRect(),G=x??{x:(N==null?void 0:N.left)??0,y:(N==null?void 0:N.top)??0};b.current={x:C.clientX,y:C.clientY,left:G.x,top:G.y},(le=($=C.currentTarget).setPointerCapture)==null||le.call($,C.pointerId),C.preventDefault()},onPointerMove:C=>{const N=b.current;N&&z(E(N.left+C.clientX-N.x,N.top+C.clientY-N.y))},onPointerUp:C=>{const N=b.current;if(b.current=null,!N)return;const G=E(N.left+C.clientX-N.x,N.top+C.clientY-N.y);z(G),g(G)},onPointerCancel:()=>{b.current=null}}:{};return h.jsx("div",{className:o?"kui-dialog-backdrop":"kui-dialog-layer",onPointerDown:o?C=>C.target===C.currentTarget&&c():void 0,children:h.jsxs("div",{ref:v,className:"kui-dialog",role:"dialog","aria-modal":o,"aria-label":l,"data-kit-ui-id":d,"data-testid":p,style:x?{position:"absolute",left:x.x,top:x.y,margin:0}:void 0,children:[h.jsx("h2",{...T,children:l}),h.jsx("div",{className:"kui-dialog-body",children:s}),h.jsx("div",{className:"kui-dialog-actions",children:u})]})})}var D1=new Set,wt=[],rT=1,hs=new Map,fg=()=>{for(const l of D1)l(wt)};function uT(l){return l==="loading"?Number.POSITIVE_INFINITY:l==="error"?6e3:4e3}function cT(l,s){clearTimeout(hs.get(l)),hs.delete(l),Number.isFinite(s)&&hs.set(l,setTimeout(()=>mu(l),s))}function nn(l,s,u={}){const{id:c,description:f,action:o,duration:d=uT(l)}=u,p=c===void 0?wt.find(v=>v.level===l&&v.title===s&&v.description===f&&!v.action):void 0,y=c??(p==null?void 0:p.id)??`toast-${rT++}`,g={id:y,level:l,title:s,description:f,action:o};return wt=wt.some(v=>v.id===y)?wt.map(v=>v.id===y?g:v):[...wt,g],fg(),cT(y,d),y}function mu(l){const s=l===void 0?wt.map(u=>u.id):[l];for(const u of s)clearTimeout(hs.get(u)),hs.delete(u);wt=l===void 0?[]:wt.filter(u=>u.id!==l),fg()}var ui=Object.assign(function(s,u,c){return nn(s,u,{description:c})},{info:(l,s)=>nn("info",l,s),success:(l,s)=>nn("success",l,s),warning:(l,s)=>nn("warning",l,s),error:(l,s)=>nn("error",l,s),loading:(l,s)=>nn("loading",l,s),dismiss:mu,promise(l,s,u={}){const c=nn("loading",s.loading,{...u,duration:Number.POSITIVE_INFINITY});return l.then(f=>nn("success",typeof s.success=="function"?s.success(f):s.success,{...u,id:c}),f=>nn("error",typeof s.error=="function"?s.error(f):s.error,{...u,id:c})),l}});function oT({offset:l=12,closeButton:s=!0}){const u=gb(),[c,f]=w.useState(wt);return w.useEffect(()=>(D1.add(f),f(wt),()=>{D1.delete(f)}),[]),h.jsx("div",{className:"kui-toasts","aria-live":"polite",style:{top:l},children:c.map(o=>h.jsxs("div",{className:"kui-toast","data-level":o.level,role:o.level==="error"?"alert":"status",children:[o.level==="loading"?h.jsx(tg,{size:16,className:"kui-toast-icon"}):null,h.jsxs("div",{className:"kui-toast-text",children:[h.jsx("div",{className:"kui-toast-title",children:o.title}),o.description?h.jsx("div",{className:"kui-toast-description",children:o.description}):null]}),o.action?h.jsx("button",{type:"button",className:"kui-toast-action",onClick:()=>{var d;(d=o.action)==null||d.onClick(),mu(o.id)},children:o.action.label}):null,s?h.jsx("button",{type:"button",className:"kui-toast-close","aria-label":u("close"),onClick:()=>mu(o.id),children:h.jsx(hu,{size:12,strokeWidth:na,"aria-hidden":"true"})}):null]},o.id))})}function p0(l){if(!Number.isFinite(l)||l<=0)return 0;const s=String(l),u=s.indexOf(".");return u===-1?0:s.length-u-1}function za(l,s){return l.toFixed(p0(s))}function dg(l){const s=l.trim().replace(",",".");if(s==="")return null;const u=Number(s);return Number.isFinite(u)?u:null}function iu(l,s,u){return Math.min(u,Math.max(s,l))}function y0(l,s){return Number(l.toFixed(p0(s)))}function vu(l,s,u){const c=y0(l,s),f=u==="floor"&&c<=l,o=u==="ceil"&&c>=l;if(f||o)return c;const d=10**p0(s);return(u==="floor"?Math.floor(l*d):Math.ceil(l*d))/d}function fT(l){return l.shiftKey?10:l.altKey?.1:1}function xa(l){return l.hot?h.jsx(dT,{...l}):h.jsx(hT,{...l})}function dT({label:l,name:s,value:u,min:c,max:f,step:o=1,unit:d,speed:p,onChange:y,onDone:g,disabled:v,testId:b,uiId:M}){const[z,x]=w.useState(null),E=w.useRef(null),T=w.useRef(null),C=w.useRef(!1),N=w.useRef(y);N.current=y,w.useEffect(()=>()=>{E.current&&Z(E.current,!0)},[]),w.useEffect(()=>{v&&E.current&&Z(E.current,!0)},[v]),w.useEffect(()=>{var q,ue;z!==null&&((q=T.current)==null||q.focus(),(ue=T.current)==null||ue.select())},[z===null]);function G(q){return iu(y0(q,o),vu(c,o,"ceil"),vu(f,o,"floor"))}function J(q){var D,L;if(v||q.button!==0)return;q.preventDefault(),(L=(D=q.currentTarget).setPointerCapture)==null||L.call(D,q.pointerId);const ue=P=>{P.key!=="Escape"||P.isComposing||P.keyCode===229||E.current!==we||(P.preventDefault(),P.stopPropagation(),Z(we,!0))},we={pointerId:q.pointerId,startX:q.clientX,startValue:u,last:u,moved:!1,sent:!1,element:q.currentTarget,onEscape:ue};E.current=we,window.addEventListener("keydown",ue,!0)}function $(q){const ue=E.current;if(v||!ue||ue.pointerId!==q.pointerId)return;if((q.buttons&1)===0){le(q,!0);return}const we=q.clientX-ue.startX;if(!ue.moved&&Math.abs(we)<=2)return;ue.moved=!0;const D=q.metaKey||q.ctrlKey||q.altKey,L=G(ue.startValue+we*(p??o)*(q.shiftKey?10:D?.1:1));L!==ue.last&&(ue.last=L,ue.sent=!0,y(L,!1))}function le(q,ue){const we=E.current;!we||we.pointerId!==q.pointerId||Z(we,ue)}function Z(q,ue){var we,D;E.current=null,window.removeEventListener("keydown",q.onEscape,!0),(D=(we=q.element).hasPointerCapture)!=null&&D.call(we,q.pointerId)&&q.element.releasePointerCapture(q.pointerId),q.moved?q.sent&&N.current(q.last,!0):!ue&&!v&&(C.current=!1,x(za(u,o)))}function ie(q){if(!C.current){if(C.current=!0,x(null),q!==null){const ue=q.trim(),we=d!=null&&d.trim()&&ue.endsWith(d.trim())?ue.slice(0,-d.trim().length):ue,D=dg(we);if(D!==null){const L=G(D);L!==u&&y(L,!0)}}g==null||g()}}function se(q){q.nativeEvent.isComposing||q.keyCode===229||(q.key==="Enter"?(q.preventDefault(),ie(q.currentTarget.value)):q.key==="Escape"&&(q.preventDefault(),ie(null)))}function ae(q){if(!v){if(q.key==="Enter"||q.key===" ")q.preventDefault(),q.stopPropagation(),C.current=!1,x(za(u,o));else if(q.key==="ArrowUp"||q.key==="ArrowDown"){q.preventDefault(),q.stopPropagation();const ue=G(u+(q.key==="ArrowUp"?1:-1)*o*(q.shiftKey?10:1));ue!==u&&y(ue,!0)}}}const de=`${za(u,o)}${d??""}`;return h.jsx("span",{className:"kui-hot-number","data-kit-ui-id":M,"data-testid":b,"data-disabled":v||void 0,children:z!==null?h.jsx("input",{ref:T,className:"kui-field kui-hot-number-input",type:"text",inputMode:"decimal","aria-label":s??l,value:z,onChange:q=>x(q.target.value),onKeyDown:se,onBlur:q=>ie(q.currentTarget.value),"data-testid":b?`${b}-input`:void 0}):h.jsx("span",{className:"kui-hot-number-value",role:"spinbutton",tabIndex:v?-1:0,"aria-label":s??l,"aria-valuemin":c,"aria-valuemax":f,"aria-valuenow":u,"aria-valuetext":de,"aria-disabled":v||void 0,title:s??l,"data-testid":b?`${b}-value`:void 0,onPointerDown:J,onPointerMove:$,onPointerUp:q=>le(q,!1),onPointerCancel:q=>le(q,!0),onLostPointerCapture:q=>le(q,!0),onKeyDown:ae,children:de})})}function hT({label:l,name:s,value:u,min:c,max:f,step:o=1,unit:d,onChange:p,disabled:y,width:g,testId:v,uiId:b,track:M}){const[z,x]=w.useState(()=>za(u,o)),E=w.useRef(!1),T=w.useRef(null),C=w.useRef(null),[N,G]=w.useState(null);w.useEffect(()=>{E.current||T.current||C.current||x(za(u,o))},[u,o]),w.useEffect(()=>{if(!y)return;const j=T.current;j&&$(j)},[y]);function J(j){const U=vu(c,o,"ceil"),Q=vu(f,o,"floor");return iu(y0(j,o),U,Q)}function $(j){var U,Q;T.current=null,(Q=(U=j.element).releasePointerCapture)==null||Q.call(U,j.pointerId),j.sent&&j.last!==u?(x(za(j.last,o)),p(j.last,!0)):x(za(u,o))}function le(j,U){const Q=dg(j);if(Q===null){x(za(u,o));return}const ve=J(Q);x(za(ve,o)),ve!==u&&p(ve,U)}function Z(j){y||(E.current=!0,x(j.target.value))}function ie(j){if(!y){if(j.key==="Enter")j.preventDefault(),E.current=!1,le(z,!0);else if(j.key==="Escape")z!==za(u,o)&&j.preventDefault(),E.current=!1,x(za(u,o));else if(j.key==="ArrowUp"||j.key==="ArrowDown"){j.preventDefault();const U=(j.key==="ArrowUp"?1:-1)*o*(j.shiftKey?10:1),Q=J(u+U);E.current=!1,x(za(Q,o)),p(Q,!0)}}}function se(){y||!E.current||(E.current=!1,le(z,!0))}function ae(j){var U,Q;y||((Q=(U=j.currentTarget).setPointerCapture)==null||Q.call(U,j.pointerId),T.current={pointerId:j.pointerId,startX:j.clientX,startValue:u,last:u,sent:!1,element:j.currentTarget})}function de(j,U){const Q=(j.clientX-U.startX)/2;return J(U.startValue+Q*o*fT(j))}function q(j){if(y)return;const U=T.current;if(!U||U.pointerId!==j.pointerId)return;const Q=de(j,U);U.last=Q,U.sent=!0,x(za(Q,o)),p(Q,!1)}function ue(j){if(y)return;const U=T.current;!U||U.pointerId!==j.pointerId||(U.last=de(j,U),U.sent=!0,$(U))}function we(j,U){const Q=U.getBoundingClientRect(),ve=Q.width>0?iu((j-Q.left)/Q.width,0,1):0;return J(c+ve*(f-c))}function D(j,U){U.last=j,G(j),x(za(j,o)),(j!==u||U.sent)&&(U.sent=!0,p(j,!1))}function L(j){var Q,ve;if(y||j.button!==0)return;(ve=(Q=j.currentTarget).setPointerCapture)==null||ve.call(Q,j.pointerId);const U={pointerId:j.pointerId,last:u,sent:!1,element:j.currentTarget};C.current=U,D(we(j.clientX,U.element),U)}function P(j){const U=C.current;y||!U||U.pointerId!==j.pointerId||D(we(j.clientX,U.element),U)}function re(j){var Q,ve;const U=C.current;!U||U.pointerId!==j.pointerId||(C.current=null,G(null),(ve=(Q=U.element).releasePointerCapture)==null||ve.call(Q,U.pointerId),U.sent?p(U.last,!0):x(za(u,o)))}function pe(j){if(y)return;const U=o*(j.shiftKey?10:1),Q={ArrowRight:u+U,ArrowUp:u+U,ArrowLeft:u-U,ArrowDown:u-U,Home:c,End:f};if(!(j.key in Q))return;j.preventDefault();const ve=J(Q[j.key]);x(za(ve,o)),ve!==u&&p(ve,!0)}const I=d?`${za(u,o)} ${d}`:za(u,o),ye=j=>h.jsx("span",{className:j,"data-testid":v?`${v}-label`:void 0,"aria-hidden":"true",onPointerDown:ae,onPointerMove:q,onPointerUp:ue,onPointerCancel:ue,children:l}),te=h.jsxs("div",{className:"kui-number-field","data-kit-ui-id":M?void 0:b,"data-testid":M?void 0:v,title:M?void 0:s,style:g&&!M?{width:g}:void 0,children:[M?null:ye("kui-number-field-label"),h.jsx("input",{className:"kui-field kui-number-field-input",type:"text",inputMode:"decimal",role:"spinbutton","aria-label":s??l,"aria-valuemin":c,"aria-valuemax":f,"aria-valuenow":u,"aria-valuetext":I,value:z,disabled:y,onChange:Z,onKeyDown:ie,onBlur:se}),d?h.jsx("span",{className:"kui-number-field-unit",children:d}):null]});if(!M)return te;const oe=N??u,k=f>c?iu((oe-c)/(f-c),0,1):0;return h.jsxs("div",{className:"kui-slider-row","data-kit-ui-id":b,"data-testid":v,title:s,"data-disabled":y||void 0,style:g?{width:g}:void 0,children:[h.jsxs("div",{className:"kui-slider-row-head",children:[ye("kui-slider-row-label"),te]}),h.jsxs("div",{className:"kui-slider",role:"slider",tabIndex:y?-1:0,"aria-label":s??l,"aria-valuemin":c,"aria-valuemax":f,"aria-valuenow":oe,"aria-valuetext":I,"aria-disabled":y||void 0,onPointerDown:L,onPointerMove:P,onPointerUp:re,onPointerCancel:re,onKeyDown:pe,"data-testid":v?`${v}-track`:void 0,children:[h.jsx("span",{className:"kui-slider-fill",style:{width:`${k*100}%`}}),h.jsx("span",{className:"kui-slider-knob",style:{left:`${k*100}%`}})]})]})}function ym({value:l,label:s,onChange:u,onDone:c,testId:f}){const o=w.useRef(!1),d=y=>{o.current||(o.current=!0,c(y))},p=y=>{y.stopPropagation(),!y.nativeEvent.isComposing&&(y.key==="Enter"?d(!0):y.key==="Escape"&&d(!1))};return h.jsx("input",{className:"kui-rename",value:l,"aria-label":s,autoFocus:!0,onFocus:y=>y.currentTarget.select(),onChange:y=>u(y.target.value),onKeyDown:p,onBlur:()=>d(!0),onPointerDown:y=>y.stopPropagation(),onClick:y=>y.stopPropagation(),onDoubleClick:y=>y.stopPropagation(),"data-testid":f})}function hi({start:l,end:s}){return h.jsxs("div",{className:"kui-panel-footer",children:[h.jsx("span",{className:"kui-panel-footer-group",children:l}),h.jsx("span",{className:"kui-panel-footer-group",children:s})]})}function H1({label:l,checked:s=!1,disabled:u,onChange:c,testId:f,id:o}){return h.jsxs("label",{className:"kui-checkbox","data-disabled":u||void 0,children:[h.jsx("input",{id:o,type:"checkbox",checked:s,disabled:u,onChange:d=>c==null?void 0:c(d.target.checked),"data-testid":f}),l]})}function Da({label:l,quiet:s,value:u,choices:c,disabled:f,onChange:o,testId:d}){return h.jsxs("label",{className:"kui-choice",children:[s?null:h.jsx("span",{children:l}),h.jsx("select",{className:"kui-field",value:u,disabled:f,"aria-label":l,onChange:p=>o(p.target.value),"data-testid":d,children:c.map(([p,y])=>h.jsx("option",{value:p,children:y},p))})]})}function hg({label:l,value:s,segments:u,disabled:c,onChange:f,testId:o}){return h.jsx("span",{className:"kui-segmented",role:"group","aria-label":l,children:u.map(d=>d.icon?h.jsx(Ge,{icon:d.icon,label:d.label,pressed:s===d.value,disabled:c,onClick:()=>f(d.value),"data-testid":o?`${o}-${d.value}`:void 0},d.value):h.jsx("button",{type:"button",className:"kui-segment-text","aria-pressed":s===d.value,disabled:c,onClick:()=>f(d.value),"data-testid":o?`${o}-${d.value}`:void 0,children:d.label},d.value))})}var mg=l=>{const s=parseInt(l.slice(1),16);return[s>>16&255,s>>8&255,s&255]},mT=l=>{const s=l/255;return s<=.03928?s/12.92:((s+.055)/1.055)**2.4};function gm(l){const[s,u,c]=mg(l).map(mT);return .2126*s+.7152*u+.0722*c}function Mm(l,s){const[u,c]=[gm(l),gm(s)].sort((f,o)=>o-f);return(u+.05)/(c+.05)}function vT(l){return Mm(l,"#ffffff")>=Mm(l,"#000000")?"#ffffff":"#000000"}function pT(l,s){const u=l[s],[c,f,o]=mg(u);return{"--kit-primary":u,"--kit-primary-text":vT(u),"--kit-primary-soft":`rgba(${c}, ${f}, ${o}, ${s==="dark"?.2:.1})`}}var bm=/^#[0-9a-fA-F]{6}$/;function yT(l){if(l==null)return null;const s=l;return typeof s.light=="string"&&typeof s.dark=="string"&&bm.test(s.light)&&bm.test(s.dark)?{light:s.light,dark:s.dark}:(console.warn("[tessera-ui] ui.brand must be { light, dark } as #rrggbb colors; the host primary is used"),null)}const _1=["menus","line","classic","focus"],gT=["menus","line","classic"],MT=720;function y1(l){return typeof l=="string"&&_1.includes(l)}function vg(l){return typeof l=="string"&&gT.includes(l)?l:null}function pg(l){return`kui.mode.${l}`}function bT(l){try{return vg(localStorage.getItem(pg(l)))}catch{return null}}function wT(l,s){try{localStorage.setItem(pg(l),s)}catch{}}const U1=Object.freeze({allowed:null,default:null});function yg(l){const s=l.allowed;return s!=null&&s.length?_1.filter(u=>s.includes(u)):_1}function ST({stored:l,rules:s,kit:u,readOnly:c}){const f=yg(s),o=s.default==="focus"?null:s.default,d=[l,o,c?"menus":null,u,"line"];for(const p of d)if(p&&f.includes(p))return p;return f.find(p=>p!=="focus")??"menus"}function zT(l,s,u,c){const f=["classic","line","menus"],o=p=>p==="menus"||s>=Math.max(MT,u[p]??0);let d=l;for(const p of f.slice(f.indexOf(l)))if(c.includes(p)&&(d=p,o(p)))return p;return d}const xT=4*1024*1024,wm=l=>l.buffer.slice(l.byteOffset,l.byteOffset+l.byteLength);function CT(l,s){const u=o=>l.request("files/stat",{handle:o}),c=async(o,d,p={})=>{const y=Math.max(1,p.chunkBytes??xT);let g=0;for(;;){const v=Math.min(d.byteLength,g+y),b=v===d.byteLength,M=wm(d.subarray(g,v)),z=b&&p.expected!==void 0?{handle:o,bytes:M,offset:g,final:b,expected:p.expected}:{handle:o,bytes:M,offset:g,final:b},x=await l.request("files/write",z,{transfer:!0});if(b)return x.version??"";g=v}},f={served:s.includes("files"),canPick:s.includes("files-pick"),canPrint:s.includes("print"),pick:async o=>(await l.request("files/pick",o)).files,create:(o,d={})=>l.request("files/create",{suggestedName:o,...d}),stat:u,read:(o,d={})=>l.request("files/read",{handle:o,...d}),readAll:async o=>{const d=[];let p=0,y="";for(;;){const b=await l.request("files/read",{handle:o,offset:p});if(y=b.version,d.push(new Uint8Array(b.bytes)),p+=b.bytes.byteLength,p>=b.size||b.bytes.byteLength===0)break}const g=new Uint8Array(p);let v=0;for(const b of d)g.set(b,v),v+=b.byteLength;return{bytes:g,version:y}},list:async o=>(await l.request("files/list",{handle:o})).files,write:c,release:async o=>{o.length&&await l.request("files/release",{handles:o})},print:async o=>{const d="handle"in o?{handle:o.handle,title:o.title}:{bytes:wm(o.bytes),mime:"application/pdf",title:o.title};return(await l.request("files/print",d,{transfer:!0})).printed===!0},writeOutputs:async(o,d,p={})=>{var g;const y=[];for(const v of o){const b=(g=p.targets)==null?void 0:g[v.id],M=b?await u(b):await f.create(v.suggestedName,{...v.mime?{mime:v.mime}:{},...p.folder?{folder:p.folder}:{}}),z=await d(v.id),x=await c(M.handle,z,M.rights.includes("create")||M.version===null?{}:{expected:M.version});y.push({...M,version:x,size:z.byteLength})}return y},onRevoked:o=>l.on("files/revoked",d=>o(Array.isArray(d==null?void 0:d.handles)?d.handles:[]))};return f}const B1=Object.freeze({hide:Object.freeze([]),disable:Object.freeze([]),add:Object.freeze([]),personal:Object.freeze([]),modes:U1}),ET=/^(command|menu|tool|panel|tab|group|action|control):(?=\S)[^*]*\*?$/,TT=/^(menu:\S.*|group:[^/\s]+\/\S.*|action)$/,kT=new Map([["command:edit.undo","action:undo"],["command:edit.redo","action:redo"]]),AT=l=>console.warn(`[kit-editor] ${l}`),pu=l=>{try{return JSON.stringify(l)??String(l)}catch{return typeof l}};function g1(l,s,u){return l===void 0?[]:Array.isArray(l)?l.filter(c=>{const f=typeof c=="string"&&ET.test(c);return f||u(`ui.${s}: ${pu(c)} is not an element id`),f}):(u(`ui.${s} is not a list`),[])}const Pr=(l,s)=>l===void 0||typeof l===s;function jT(l,s){const u=l&&typeof l=="object"?l:{},c=u.label&&typeof u.label=="object"&&!Array.isArray(u.label)?u.label:null,f=c?Object.values(c):[];return typeof u.id=="string"&&u.id!==""&&typeof u.place=="string"&&TT.test(u.place)&&c!==null&&f.length>0&&f.every(o=>typeof o=="string"&&o.length>0)&&Pr(u.icon,"string")&&Pr(u.shortcut,"string")&&Pr(u.disabled,"boolean")&&Pr(u.pressed,"boolean")?{id:u.id,place:u.place,label:{...u.label},icon:u.icon,shortcut:u.shortcut,disabled:u.disabled,pressed:u.pressed}:(s(`ui.add: ${pu(l)} is not a valid button`),null)}function NT(l,s){const u=new Set,c=[];for(const f of l){if(u.has(f.id)){s(`ui.add: duplicate button id "${f.id}"`);continue}u.add(f.id),c.push(f)}return c}function OT(l,s){if(l===void 0)return U1;if(l===null||typeof l!="object"||Array.isArray(l))return s("ui.modes is not an object"),U1;const u=l;let c=null;u.allowed!==void 0&&(Array.isArray(u.allowed)?(c=u.allowed.filter(o=>(y1(o)||s(`ui.modes.allowed: ${pu(o)} is not a display mode`),y1(o))),c.length||(c=null)):s("ui.modes.allowed is not a list"));let f=null;return u.default!==void 0&&(y1(u.default)?f=u.default:s(`ui.modes.default: ${pu(u.default)} is not a display mode`)),{allowed:c,default:f}}function Sm(l,s=AT){if(l==null)return B1;if(typeof l!="object"||Array.isArray(l))return s("ui is not an object"),B1;const u=l;u.add!==void 0&&!Array.isArray(u.add)&&s("ui.add is not a list");const c=Array.isArray(u.add)?u.add.map(d=>jT(d,s)).filter(d=>d!==null):[],f=NT(c,s);let o=[];return u.personal!==void 0&&(u.personal!==null&&typeof u.personal=="object"&&!Array.isArray(u.personal)?o=g1(u.personal.hide,"personal.hide",s):s("ui.personal is not an object")),{hide:g1(u.hide,"hide",s),disable:g1(u.disable,"disable",s),add:f,personal:o,modes:OT(u.modes,s)}}function RT(l,s){return l.endsWith("*")?s.startsWith(l.slice(0,-1)):l===s}function LT(l,s=[]){const u=[l],c=l.startsWith("menu:"),f=c?l.slice(5).split("/"):s,o=c?f.length-1:f.length;for(let p=1;p<=o;p+=1)u.push(`menu:${f.slice(0,p).join("/")}`);const d=kT.get(l);return d&&u.push(d),u}const gg="action:more";function Oa(l,s,u=[]){const c=LT(s,u),f=y=>y.some(g=>c.some(v=>RT(g,v))),o=f(l.hide),d=!o&&f(l.disable),p=!o&&s!==gg&&f(l.personal);return{hostHidden:o,hostDisabled:d,personalHidden:p,hidden:o||p,disabled:d,denied:o||d}}function Mg(l,s){return l.add.filter(u=>u.place===s)}function DT(l,s){const u=c=>Object.hasOwn(l.label,c)?l.label[c]:void 0;return u(s)??u(s.split("-")[0])??u("en-US")??l.id}function Wr(l,s){const u=s==null?`\`${l}\``:`step ${s} (\`${l}\`)`;return new ta(-32e3,`${u} is not allowed in this editor`,s==null?{reason:"not-allowed",command:l}:{reason:"not-allowed",command:l,step:s})}function HT(l,s,u){return s.findIndex(c=>Oa(l,`command:${c.command}`,u(c.command)).denied)}function _T(l,s){return s.flatMap(u=>{const c=Oa(l,`command:${u.id}`,u.menu);return c.hostHidden?[]:[c.hostDisabled?{...u,enabled:!1}:u]})}function bg(l,s,u){let c=l,f=null;const o=new Set,d=p=>{c=f?{...p,personal:f}:p;for(const y of o)y()};return{get:()=>c,subscribe:p=>(o.add(p),()=>void o.delete(p)),replace:d,customizable:s!==null,setPersonal:async p=>{const y=[...new Set(p)];f=y,d({...c,personal:y});try{s&&await s(y)}finally{f===y&&(f=null)}},action:u}}const UT=["--kit-primary","--kit-primary-text","--kit-primary-soft"];function zm(l,s=null,u=document.documentElement){if(u.dataset.brand==="kit")for(const f of UT)u.style.removeProperty(f);for(const[f,o]of Object.entries(l.tokens))f.startsWith("--")&&u.style.setProperty(f,o);const c=s!==null&&l.brand!=="host";if(c)for(const[f,o]of Object.entries(pT(s,l.colorScheme)))u.style.setProperty(f,o);u.dataset.brand=c?"kit":"host",u.style.colorScheme=l.colorScheme,u.dataset.colorScheme=l.colorScheme}const ju=()=>typeof navigator<"u"&&/Mac|iPhone|iPad/i.test(navigator.platform);function BT(l){return new Promise(s=>{const u=`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`,c=()=>window.parent.postMessage({kitionKitUi:1,ready:o1,id:u},"*"),f=o=>{if(o.source!==window.parent)return;if(F6(o.data)&&o.data.hello===o1){c();return}if(!Q6(o.data)||o.data.protocol!==o1||!o.ports[0]||o.data.id!=null&&o.data.id!==u)return;window.removeEventListener("message",f);const d=new J6(o.ports[0],"k");d.handle("ui/initialize",p=>new Promise((y,g)=>{let v=p.document.bytes??null;const b=p.capabilities.includes("replica")&&(l.capabilities??[]).includes("replica"),M={read:async C=>{if(v&&C===p.document.path){const G=v;return v=null,{bytes:G,stamp:p.document.version??null}}const N=await d.request("host/read",{path:C});return{bytes:N.bytes,stamp:N.version}},stamp:async C=>(await d.request("host/stamp",{path:C})).version,write:async(C,N,G)=>{const J=N.buffer.slice(N.byteOffset,N.byteOffset+N.byteLength);return(await d.request("host/write",{path:C,bytes:J,mode:"save",...G===void 0?{}:{expected:G}},{transfer:!0})).version||null},lend:()=>p.document.lend??null};b&&(M.replicaRead=async C=>{const N=await d.request("host/replicaRead",{path:C});return N&&N.snapshot instanceof ArrayBuffer&&N.blobs instanceof ArrayBuffer&&typeof N.fileStamp=="string"?N:null},M.replicaWrite=async(C,N)=>{await d.request("host/replicaWrite",{path:C,...N},{transfer:!0})});const z=yT(l.brand);zm(p.theme,z);const x=bg(Sm(p.ui),p.capabilities.includes("customize")?async C=>void await d.request("host/customize",{personal:{hide:C}}):null,C=>d.notify("ui/action",C));d.on("ui/configure",C=>x.replace(Sm(C==null?void 0:C.ui))),document.documentElement.lang=p.locale;const E=p.shortcuts,T=C=>{E.some(N=>v5(N,C,ju()))&&(C.preventDefault(),C.stopPropagation(),d.notify("host/shortcut",{key:C.key,code:C.code,meta:C.metaKey,ctrl:C.ctrlKey,shift:C.shiftKey,alt:C.altKey}))};window.addEventListener("keydown",T,!0),d.on("ui/theme",({theme:C})=>zm(C,z)),d.on("ui/locale",({locale:C})=>{document.documentElement.lang=C}),s({peer:d,init:p,files:M,kitFiles:CT(d,p.capabilities),replica:b,readOnly:p.document.readOnly===!0,view:Fh(p.document.view),permissions:W6(p.document.permissions),watermark:P6(p.document.watermark),onReveal:C=>d.on("document/reveal",N=>{const G=Fh(N==null?void 0:N.view);G&&C(G)}),ui:x,brand:z,kit:{id:l.id,version:l.version},display:vg(l.display),declaration:l.ui??null,opened:(C=[])=>{const N=[...l.capabilities??["ai"],...l.ui?["ui-config"]:[]];y({kit:{id:l.id,version:l.version},capabilities:[...N,...C.filter(G=>!N.includes(G))]})},failed:C=>g(C),changed:C=>d.notify("document/changed",C),notify:C=>d.notify("host/notify",C),exportFile:async(C,N)=>{const G=N.buffer.slice(N.byteOffset,N.byteOffset+N.byteLength);return(await d.request("host/write",{path:C,bytes:G,mode:"export"},{transfer:!0})).path},openAgent:async C=>{await d.request("host/openAgent",C?{prompt:C}:{})},pick:async(C,N)=>(await d.request("host/pick",{purpose:C,accept:N})).path,pickLinks:async C=>(await d.request("links/pick",C)).links,hasService:C=>p.capabilities.includes(`${Zh}${C}`),service:async(C,N)=>{if(!p.capabilities.includes(`${Zh}${C}`))throw new ta(-32e3,`the host does not serve ${C}`,{reason:"not-allowed"});const G=C==="file.saveAs";return await d.request("host/service",{service:C,params:N},G?{transfer:!0}:void 0)},commentAnchors:p.capabilities.includes("comment-anchors"),onComments:C=>d.on("comments/show",N=>{const G=Array.isArray(N==null?void 0:N.threads)?N.threads:[];C(G.flatMap(J=>{const $=Ih(J==null?void 0:J.anchor);return $&&typeof(J==null?void 0:J.id)=="string"?[{id:J.id,anchor:$,resolved:J.resolved===!0,count:Number.isSafeInteger(J.count)?J.count:0}]:[]}))}),activateComment:C=>d.notify("comments/activated",{id:C}),locateComments:C=>d.handle("comments/locate",async N=>{const G=(Array.isArray(N==null?void 0:N.anchors)?N.anchors:[]).map(le=>Ih(le)),J=await C(G.filter(le=>le!==null));let $=0;return{found:G.map(le=>le?J[$++]===!0:!1)}}),close:()=>{window.removeEventListener("keydown",T,!0),d.close()}})}))};window.addEventListener("message",f),c()})}class os extends Error{constructor(s){super(s.message),this.data=s,this.name="KitModelError"}}const VT=new Set(["edit.undo","undo"]),qT=new Set(["edit.redo","redo"]),Ht="read-only",On=Object.freeze({viewingGroups:Object.freeze(["view","select","selection","go","navigate","help","playback","transport","playhead","caret"]),viewingCommands:Object.freeze(["markers.goNext","markers.goPrev","markers.goToIn","markers.goToOut","source.open","source.setPlayhead","source.inspect","sequence.open","sequence.moveTab","sequence.inspect","sequence.matchFrame","sequence.revealInProject"]),editingCommands:Object.freeze(["edit.undo","edit.redo","undo","redo","u"]),documentSettings:Object.freeze(["view.freezePanes","view.freezeTopRow","view.freezeFirstColumn","view.unfreezePanes","view.gridlines","view.headings","view.showZeros","view.rightToLeft","view.newWindow","view.addGuide","view.clearGuides","view.importGuides","view.moveGuide","view.removeGuide","view.lookAtSelected","view.lookAtAll","view.reset3DView","view.newGuide","view.newGuideLayout","view.newGuidesFromShape","view.deleteGuide","view.clearCanvasGuides","view.clearSelectedArtboardGuides","view.clearSlices","view.lockSlices","select.toWorkPath","select.convertToShape","select.saveSelection","select.float","select.drop","view.guides.make","view.guides.release","view.guides.clear","view.guides.lock","view.saved.new","view.saved.edit","select.save"]),editingGroups:Object.freeze(["file"]),fileOutputs:/^file\.(export|saveCopy|saveACopy|print)/,refusedTools:Object.freeze(["pointer","toolKey","toolText"]),refusedMethods:Object.freeze(["executeAs","undo","redo","importChanges","addBlobs"])});function GT(l){const{id:s}=l,u=s.split(".")[0]??"";return On.editingCommands.includes(s)||On.documentSettings.includes(s)?!0:On.editingGroups.includes(u)?!On.fileOutputs.test(s):On.viewingCommands.includes(s)||On.viewingGroups.includes(u)?!1:l.mutates===!0}function YT(l,s){return!s||!l?new Set:new Set(l.filter(u=>typeof u=="string"&&!On.editingCommands.includes(u)&&!On.editingGroups.includes(u.split(".")[0]??"")))}function wg(l,s){return s.size===0?null:VT.has(l)?"undo":qT.has(l)?"redo":null}function yu(l,s){return GT(l)&&!s.has(l.id)&&wg(l.id,s)===null}function $T(l,s){return s.size>0&&yu(l,s)}class gu extends Error{constructor(u,c){super(c??`${u} is not allowed: the document is read-only`);sa(this,"reason",Ht);this.name="ReadOnlyError"}}function Sg(l){return l instanceof gu||l instanceof Error&&l.reason===Ht}const V1="unsupported";class g0 extends Error{constructor(u,c){super(u);sa(this,"reason",xu);this.errors=c,this.name="KitParamsError"}}class zg extends Error{constructor(s,u){super(u),this.reason=s,this.name="KitEngineRefusal"}}const M1={width:0,height:0,pinned:{left:0,top:0},revision:0,dirty:!1,canUndo:!1,canRedo:!1,inspected:{}};class bs{constructor(s,u){sa(this,"closed",!1);sa(this,"pending",new Map);sa(this,"nextId",1);sa(this,"failure",null);this.worker=s,this.info=u}static async open(s,u,c,f=null,o=null,d=!1,p=!1){const y=new Worker(new URL(""+new URL(""+new URL("kitEngine.worker-9PIHJagj-Dwbox6hp.js",import.meta.url).href,import.meta.url).href,import.meta.url),{type:"module"}),g=new bs(y,M1);y.onmessage=v=>g.settle(v.data),y.onerror=v=>g.fail(new Error(v.message||"the kit engine stopped"));try{const v=o==null?void 0:o.stored;return g.info=await g.call({method:"open",manifest:s,name:u,bytes:c,lent:f,replica:o,readOnly:d,canComment:p},v?[c,v.snapshot,v.blobs]:[c]),g}catch(v){throw g.dispose(),v}}static async create(s,u,c,f,o=null,d=!1){const p=new Worker(new URL(""+new URL(""+new URL("kitEngine.worker-9PIHJagj-Dwbox6hp.js",import.meta.url).href,import.meta.url).href,import.meta.url),{type:"module"}),y=new bs(p,M1);p.onmessage=g=>y.settle(g.data),p.onerror=g=>y.fail(new Error(g.message||"the kit engine stopped"));try{return y.info=await y.call({method:"create",manifest:s,name:u,width:c,height:f,lent:o,readOnly:d}),y}catch(g){throw y.dispose(),g}}get width(){return this.info.width}get height(){return this.info.height}get pinned(){return this.info.pinned}settle(s){const u=this.pending.get(s.id);u&&(this.pending.delete(s.id),s.ok===!0?u.resolve(s.value):s.data?u.reject(new os(s.data)):s.reason===Ht?u.reject(new gu("",s.error)):s.reason===xu?u.reject(new g0(s.error,s.errors??[])):s.reason===V1?u.reject(new zg(V1,s.error)):u.reject(new Error(s.error)))}fail(s){this.failure=s;for(const u of this.pending.values())u.reject(s);this.pending.clear()}call(s,u=[]){if(this.failure)return Promise.reject(this.failure);const c=this.nextId++;return new Promise((f,o)=>{this.pending.set(c,{resolve:f,reject:o}),this.worker.postMessage({id:c,request:s},u)})}async execute(s,u={},c,f){const o={method:"execute",command:s,params:u,...c?{origin:c}:{},...f?{agent:{state:f.state.state,set:f.set}}:{}},{result:d,info:p,state:y,closed:g}=await this.call(o);return g&&(this.closed=!0,this.info=M1),p&&(this.info=p),f&&y!==void 0&&(f.state.state=y),d}async render(s,u,c,f,o){return new Uint8Array(await this.call({method:"render",x:s,y:u,scale:c,width:f,height:o}))}async renderArea(s,u,c,f,o,d){return new Uint8Array(await this.call({method:"renderArea",x0:s,y0:u,x1:c,y1:f,width:o,height:d}))}async commands(){return await this.call({method:"commands"})}async disabledCommands(){return await this.call({method:"disabledCommands"})}async check(){return await this.call({method:"check"})}async lendHandle(s,u){await this.call({method:"lendHandle",handle:s,bytes:u},u?[u]:[])}async takeOutput(s,u){return new Uint8Array(await this.call({method:"takeOutput",id:s,...u===void 0?{}:{max:u}}))}async save(){return(await this.serialize()).bytes}async serialize(){const s=await this.call({method:"save"});return{bytes:new Uint8Array(s.bytes),revision:s.revision}}async saveWithReplica(){const s=await this.call({method:"saveWithReplica"});return{bytes:new Uint8Array(s.bytes),replica:s.replica,revision:s.revision}}async replicaVersion(){return await this.call({method:"replicaVersion"})}async replicaExport(s){return await this.call({method:"replicaExport",since:s})}async replicaImport(s,u){const{damage:c,info:f}=await this.call({method:"replicaImport",changes:s,blobs:u});return this.info=f,c}async replicaDocId(){return await this.call({method:"replicaDocId"})}async replicaMerge(s,u,c,f){const{summary:o,info:d}=await this.call({method:"replicaMerge",changes:s,blobs:u,origin:c,schema:f});return this.info=d,o}async replicaCompare(s,u){return await this.call({method:"replicaCompare",changes:s,schema:u})}async modelVersion(){return await this.call({method:"modelVersion"})}async premiseRead(s,u){return this.call({method:"premiseRead",name:s,params:u})}async inspectAt(s,u){return await this.call({method:"inspectAt",context:s,part:u})}async modelChanges(s,u){return await this.call({method:"modelChanges",since:s,schema:u})}async modelDescribe(s){return await this.call({method:"modelDescribe",schema:s})}async agentReply(s){return await this.call({method:"modelReply",value:s})}async modelBatch(s,u){const{answer:c,info:f}=await this.call({method:"modelBatch",request:s,schema:u});return this.info=f,c}async markSaved(s){this.info=await this.call({method:"markSaved",revision:s})}async refreshInfo(){return this.info=await this.call({method:"info"}),this.info}async invoke(s,...u){return await this.call({method:"invoke",name:s,args:u})}async tool(s,u=[],c=!1){const{value:f,info:o}=await this.call({method:"tool",name:s,args:u,settled:c});return o&&(this.info=o),{value:f,changed:o!=null}}dispose(){this.worker.terminate(),this.fail(new Error("the document was closed"))}}async function XT(l,s,u,c=!1){if(!l.replicaRead)return null;try{const f=await l.replicaRead(s);if(!f)return null;if(c)return{snapshot:f.snapshot,blobs:f.blobs};const o=u??await l.stamp(s);return o&&f.fileStamp===o?{snapshot:f.snapshot,blobs:f.blobs}:null}catch{return null}}async function KT(l,s,u,c,f){const o=await l.write(s,u,f)||await l.stamp(s).catch(()=>null);if(c&&o&&l.replicaWrite)try{await l.replicaWrite(s,{...c,fileStamp:o})}catch(d){console.warn("[kit] could not store the document replica",d)}return o}function IT(l){const s=l!==null&&typeof l=="object"?l.damage:null;if(s===null||typeof s!="object")return null;const{x0:u,y0:c,x1:f,y1:o}=s;return[u,c,f,o].every(d=>typeof d=="number"&&Number.isFinite(d))&&f>u&&o>c?{x0:u,y0:c,x1:f,y1:o}:null}function ZT(){let l={tick:0,damage:null};const s=new Set;return{get:()=>l,subscribe(u){return s.add(u),()=>void s.delete(u)},bump(u){l={tick:l.tick+1,damage:u};for(const c of s)c()}}}const q1=new WeakMap;function FT(l,s){const u=q1.get(l);return u?(u.current=s,()=>{u.current===s&&(u.current=null)}):()=>{}}class QT extends Error{constructor(s){super(`${s} changed on disk since it was opened; merge the change or keep yours before saving`),this.name="FileChangedError"}}const xm={x0:0,y0:0,x1:0,y1:0},JT=2e3;function PT(l){return l instanceof Error?l.message:String(l)}function WT(l,s,u,c,f,o={}){const d=o.readOnly===!0,p=d&&o.canComment===!0,y=o.replicaMergesFile===!0,g=w.useRef(o.followFile);g.current=o.followFile;const v=w.useRef(null),b=w.useRef(f);b.current=f;const M=w.useRef(null),z=w.useRef(!1),[x,E]=w.useState(null),[T,C]=w.useState(null),[N,G]=w.useState(null),[J,$]=w.useState({revision:0,damage:null}),[le,Z]=w.useState(!1),[ie,se]=w.useState(null),[ae,de]=w.useState(null),[q,ue]=w.useState(!1),[we,D]=w.useState(!1),[L,P]=w.useState(0),re=w.useRef(null);re.current??(re.current=ZT());const pe=re.current,I=w.useCallback((H=null)=>{const F=v.current;F&&(C(F.info),G(b.current(F.info)),Z(F.info.dirty),$(ce=>({revision:ce.revision+1,damage:H})))},[]),ye=w.useCallback(async H=>{var F;z.current=!0;try{const{bytes:ce,stamp:me}=await l.read(u);if(!H())return;const ze=await XT(l,u,me,y);if(!H())return;const ke=performance.now(),We=u.split("/").filter(Boolean).pop()||u,ea=await bs.open(s,We,ce,((F=l.lend)==null?void 0:F.call(l,u))??null,l.replicaWrite?{stored:ze,follow:!0}:null,d,p);if(de(Math.round(performance.now()-ke)),!H()){ea.dispose();return}const Ie=v.current;v.current=ea,M.current=me,E(ea),D(!1),se(null),I(),Ie==null||Ie.dispose()}finally{z.current=!1}},[p,l,s,y,u,d,I]);w.useEffect(()=>{let H=!0;return ye(()=>H).catch(F=>{H&&se(PT(F))}),()=>{H=!1}},[L,ye]),w.useEffect(()=>()=>{var H;(H=v.current)==null||H.dispose(),v.current=null},[u]);const te=w.useRef(new Set),oe=w.useCallback(H=>{te.current.add(H);const F=()=>te.current.delete(H);return H.then(F,F),H},[]),k=w.useCallback(async()=>{for(;te.current.size;)await Promise.allSettled([...te.current])},[]),j=w.useCallback(async(H=()=>!0)=>{const F=v.current;if(!(!F||z.current||!M.current))try{const ce=await l.stamp(u);if(!H()||!ce||ce===M.current||z.current||v.current!==F||(await k(),!H()||z.current||v.current!==F))return;if(F.info.dirty){D(!0);return}const me=g.current;if(me){z.current=!0;let ze=!1;try{ze=await me(F,ce)===!0}catch(ke){console.warn("[kit] could not follow the changed file; reopening it",ke)}finally{z.current=!1}if(ze){v.current===F&&(M.current=ce,await F.refreshInfo().catch(()=>{}),v.current===F&&I());return}}H()&&await ye(H)}catch{}},[l,ye,u,I,k]);w.useEffect(()=>{let H=!0;const F=window.setInterval(()=>void j(()=>H),JT);return()=>{H=!1,window.clearInterval(F)}},[c,j]);const U=w.useRef(null),Q=w.useCallback(H=>U.current?U.current(H):H(),[]),ve=w.useCallback(async(H,F,ce,me)=>{const ze=v.current;if(!ze)return null;const ke=me.skipUnchangedPaint?{revision:ze.info.revision,inspected:JSON.stringify(ze.info.inspected)}:null,We=await ze.execute(H,F,me.origin,me.agent);if(v.current===ze){if(ze.closed)return ze.dispose(),v.current=null,E(null),C(null),G(null),Z(!1),D(!1),We;const ea=me.refresh??"all",Ie=ke!=null&&ze.info.revision===ke.revision&&JSON.stringify(ze.info.inspected)===ke.inspected;ea==="all"?I(Ie?xm:ce):ea==="repaint"&&pe.bump(ce)}return We},[I,pe]),Se=w.useCallback(async(H,F={},ce=null,me={})=>v.current?oe(Q(()=>ve(H,F,ce,me))):null,[Q,ve,oe]),Le=w.useCallback(async(H,F=[],ce=!1)=>{const me=v.current;if(!me)return null;const ze=me.info.revision,{value:ke,changed:We}=await oe(me.tool(H,F,ce));return v.current===me&&We&&I(me.info.revision===ze?xm:IT(ke)),ke},[I,oe]);q1.has(Le)||q1.set(Le,U);const ge=w.useCallback(async()=>v.current?v.current.commands():[],[]),Te=w.useCallback(async()=>Q(async()=>v.current?v.current.disabledCommands():[]),[Q]),Ha=w.useCallback(async()=>{const H=v.current;if(H){if(d)throw new gu("Save");ue(!0),z.current=!0;try{const F=M.current,ce=F?await l.stamp(u).catch(()=>null):null;if(F&&ce&&ce!==F)throw D(!0),new QT(u);const{bytes:me,replica:ze,revision:ke}=await Q(async()=>l.replicaWrite?H.saveWithReplica():{...await H.serialize(),replica:null});M.current=await KT(l,u,me,ze,F),v.current===H&&await H.markSaved(ke),D(!1),I()}finally{z.current=!1,ue(!1)}}},[l,Q,u,d,I]),Vt=w.useMemo(()=>{const H=()=>{if(!v.current)throw new Error("the document is still opening");return v.current};return{version:()=>H().replicaVersion(),exportChanges:F=>H().replicaExport(F),importChanges:async(F,ce)=>{const me=H(),ze=await me.replicaImport(F,ce);return v.current===me&&I(),ze},docId:()=>H().replicaDocId()}},[I]),ne=w.useMemo(()=>{const H=()=>{if(!v.current)throw new Error("the document is still opening");return v.current};return{describe:F=>H().modelDescribe(F),version:()=>Q(()=>H().modelVersion()),changes:(F,ce)=>Q(()=>H().modelChanges(F,ce)),batch:(F,ce)=>Q(async()=>{const me=H();try{return await me.modelBatch(F,ce)}finally{v.current===me&&I()}})}},[Q,I]),he=w.useMemo(()=>{const H=()=>{if(!v.current)throw new Error("the document is still opening");return v.current};return{open:()=>Q(async()=>{var ea;const F=H();if(d)throw new gu("a draft");const ce=await F.replicaVersion(),{bytes:me,replica:ze}=await F.saveWithReplica();if(!ze)throw new Error("the kit's engine keeps no replica to draft on");const ke=u.split("/").filter(Boolean).pop()||u,We=me.slice().buffer;return{engine:await bs.open(s,ke,We,((ea=l.lend)==null?void 0:ea.call(l,u))??null,{stored:ze,follow:!0},!1),base:ce}}),merge:(F,ce,me,ze)=>Q(async()=>{const ke=H();try{return await ke.replicaMerge(F,ce,me,ze)}finally{v.current===ke&&I()}}),compare:(F,ce)=>H().replicaCompare(F,ce)}},[l,s,Q,u,d,I]),Ee=w.useCallback(()=>P(H=>H+1),[]),xe=w.useCallback(async H=>{H&&(M.current=H,await l.stamp(u).catch(()=>null)===H&&D(!1))},[l,u]),Oe=w.useCallback(async()=>{D(!1);const H=await l.stamp(u).catch(()=>null);H&&(M.current=H)},[l,u]),je=w.useMemo(()=>({get:pe.get,subscribe:pe.subscribe}),[pe]);return{path:u,manifest:s,doc:x,info:T,state:N,change:J,repaints:je,dirty:le,failure:ie,openMs:ae,saving:q,conflict:we,run:Se,tool:Le,commands:ge,disabledCommands:Te,save:Ha,replica:Vt,model:ne,draft:he,reopen:Ee,keepMine:Oe,checkFile:j,holdFile:xe}}async function G1(l,s){var p;const u=Math.min(1,s/Math.max(1,l.width,l.height)),c=Math.max(1,Math.round(l.width*u)),f=Math.max(1,Math.round(l.height*u)),o=await l.render(0,0,u,c,f),d=document.createElement("canvas");return d.width=c,d.height=f,(p=d.getContext("2d"))==null||p.putImageData(new ImageData(new Uint8ClampedArray(o.buffer,o.byteOffset,o.byteLength),c,f),0,0),d.toDataURL("image/png").replace(/^data:image\/png;base64,/,"")}async function ek(l,s){try{return await G1(l,s)}catch{return null}}const Cm="there is no draft of this document: run the agent with `draft: true` first";class ak{constructor(s){sa(this,"current",null);sa(this,"queue",Promise.resolve());sa(this,"closed",!1);this.host=s}info(){const s=this.current;return s?{state:s.state,revision:s.engine.info.revision}:{state:"none",revision:null}}serial(s){const u=this.queue.then(s,s);return this.queue=u.catch(()=>{}),u}tell(){this.host.changed(this.info())}need(){if(!this.current)throw new Error(Cm);return this.current}engine(s){return this.serial(async()=>{if(this.closed)throw new Error("the document was closed");if(!this.current){if(!s)throw new Error(Cm);const{engine:u,base:c}=await this.host.open();if(this.closed)throw u.dispose(),new Error("the document was closed");this.current={engine:u,base:c,state:"open"},this.tell()}return this.current.engine})}edited(){this.current&&(this.current.state="open",this.tell())}ready(){return this.serial(async()=>(this.need().state="ready",this.tell(),this.info()))}reopen(){return this.serial(async()=>(this.need().state="open",this.tell(),this.info()))}changes(s){return s.engine.replicaExport(s.base.slice(0))}compare(s,u){return this.serial(async()=>{const c=this.need(),{changes:f}=await this.changes(c),o=await this.host.compare(f,u),[d,p]=[await this.host.preview(s),await ek(c.engine,s)];return{summary:o,before:d,after:p}})}merge(s,u){return this.serial(async()=>{const c=this.need(),{changes:f,blobs:o}=await this.changes(c),d=await this.host.merge(f,o,s,u);return this.close(),{merged:!0,summary:d}})}discard(){return this.serial(async()=>(this.close(),this.info()))}close(){const s=this.current;s&&(this.current=null,s.engine.dispose(),this.tell())}attach(){this.closed=!1}dispose(){this.closed=!0;const s=this.current;this.current=null,s==null||s.engine.dispose()}}const tk=[[/^tool-selection$/,du],[/^tool-page$/,l0],[/^tool-gap$/,C4],[/^tool-(collector|placer)/,H4],[/^tool-(rect-frame|ellipse-frame|polygon-frame)/,ps],[/^tool-note/,AE],[/^tool-color-theme/,U4],[/^tool-gradient-feather/,ds],[/^tool-(direct|group-select|live-select|perspective-select)/,IC],[/^tool-magic-wand/,P4],[/^tool-lasso/,LC],[/^tool-(pen|anchor)/,V4],[/^tool-curvature/,d0],[/^tool-(type|touch-type)/,Tu],[/^tool-line$/,KC],[/^tool-arc/,oE],[/^tool-spiral/,yE],[/^tool-(rect-grid|polar-grid|perspective)/,T1],[/^tool-(rect|rounded-rect|polygon|star|flare)/,Ss],[/^tool-ellipse/,aC],[/^tool-(brush|blob-brush)/,w4],[/^tool-(pencil|smooth|shaper|join|path-eraser)/,Ms],[/^tool-eraser?$/,MC],[/^tool-(scissors|knife|mirror-cut|line-cut|rect-cut)/,c0],[/^tool-(rotate|reflect)/,Y4],[/^tool-scale/,u0],[/^tool-shear/,R4],[/^tool-reshape/,KE],[/^tool-free-transform/,IE],[/^tool-puppet/,eg],[/^tool-(width|warp|twirl|pucker|bloat|scallop|crystallize|wrinkle)/,W4],[/^tool-shape-builder/,Eu],[/^tool-bucket/,_4],[/^tool-mesh/,ZC],[/^tool-gradient/,ds],[/^tool-eyedropper/,sE],[/^tool-measure/,Cu],[/^tool-blend/,ds],[/^tool-artboard/,ps],[/^tool-slice/,E4],[/^tool-move$/,D4],[/^tool-copy$/,di],[/^tool-offset$/,dC],[/^tool-extend$/,FC],[/^tool-fillet$/,hC],[/^tool-hand/,j4],[/^tool-zoom/,ag]],nk=[[/^dim-?linear$/,mE],[/^dim-?aligned$/,Cu],[/^dim-?radius$/,cE],[/^dim-?diameter$/,vC]];function M0(l,s){var u,c;return(s?(u=nk.find(([f])=>f.test(s)))==null?void 0:u[1]:void 0)??((c=tk.find(([f])=>f.test(l)))==null?void 0:c[1])??Eu}const lk=[[/pivot/,HE],[/sparkline/,Hx],[/chart|graph/,Qx],[/table/,F4],[/picture|image|photo/,k1],[/\bicons?\b|sticker/,kE],[/shape|drawing/,Eu],[/header/,B4],[/footer/,aE],[/hyperlink|\blink/,oi],[/bookmark/,M4],[/equation|formula|function/,h0],[/sum|sigma/,ME],[/symbol|special char/,WC],[/check ?box|checkbox/,zE],[/comment|note/,i0],[/text|word ?art|caption/,Tu],[/signature/,bE],[/date|time/,Zx],[/number|numbering/,N4],[/video|movie|media/,J4],[/audio|sound|music/,JC],[/qr|barcode/,uE],[/block|object|3d|model/,b4],[/layer/,fu],[/layout|template|theme/,A1],[/page|section|break|sheet|slide/,xC],[/rows?\b/,$4],[/columns?\b/,C4],[/filter/,A4],[/sort/,a0],[/ungroup/,ku],[/group/,ys],[/find|search/,K4],[/replace/,G4],[/spell|proof/,wE],[/translat|language/,RC],[/print/,s0],[/paste/,x4],[/copy|duplicate/,di],[/cut\b/,c0],[/delete|remove|clear/,Hn],[/refresh|recalc/,r0],[/protect|lock/,gs],[/name|label|tag/,Q4],[/show|hide|view/,vs],[/option|setting|propert/,o0],[/\bfile\b|document/,l0]],ik=[[/^(?:bold)$/,Xx],[/^(?:italic)$/,R4],[/^(?:underline)$/,$E],[/^(?:strike|strikethrough)$/,jE],[/^(?:subscript)$/,NE],[/^(?:superscript)$/,LE],[/^(?:deselect|none)$/,R1],[/^(?:inverse|invert)$/,fC],[/^(?:pan)$/,j4],[/^(?:measure)$/,Cu],[/^(?:collapse)$/,Jx],[/^(?:expand)$/,eC],[/^(?:bind|attach)$/,oi],[/^(?:audit|check|verify|validate)$/,gE],[/^(?:recover|repair)$/,DC],[/^(?:purge)$/,Hn],[/^(?:sketch)$/,Ms],[/^(?:read)$/,Kx],[/^(?:left)$/,Bx],[/^(?:right)$/,om],[/^(?:up)$/,cu],[/^(?:down)$/,uu],[/^(?:home|start)$/,qx],[/^(?:end)$/,Yx],[/^(?:lift)$/,lC],[/^(?:extract)$/,nC],[/^(?:shuttle)$/,bC],[/^(?:tick|advance)$/,pm],[/^(?:batch)$/,fu],[/^(?:redact)$/,ou],[/^(?:reselect)$/,du],[/^(?:click|tap|press)$/,L4],[/^(?:undo)$/,m0],[/^(?:redo)$/,q4],[/^(?:save)$/,X4],[/^(?:export|publish)$/,zC],[/^(?:import|place)$/,SC],[/^(?:open|browse)$/,EC],[/^(?:close)$/,hu],[/^(?:print)$/,s0],[/^(?:delete|remove|clear|erase)$/,Hn],[/^(?:duplicate|copy|clone)$/,di],[/^(?:cut)$/,c0],[/^(?:paste)$/,x4],[/^(?:rename)$/,iE],[/^(?:find|search|locate)$/,K4],[/^(?:replace)$/,G4],[/^(?:align|distribute)$/,_x],[/^(?:rotate)$/,Y4],[/^(?:flip|mirror|reflect)$/,CC],[/^(?:move|nudge|offset|shift)$/,D4],[/^(?:scale|resize|transform|warp|distort)$/,u0],[/^(?:merge|join|combine|flatten)$/,$C],[/^(?:split|divide|separate)$/,SE],[/^(?:group)$/,ys],[/^(?:ungroup)$/,ku],[/^(?:lock)$/,gs],[/^(?:unlock)$/,N1],[/^(?:hide)$/,ou],[/^(?:show|reveal|view)$/,vs],[/^(?:zoom)$/,ag],[/^(?:play|preview)$/,rE],[/^(?:pause)$/,nE],[/^(?:stop)$/,Ss],[/^(?:record|capture)$/,yC],[/^(?:render|bake|encode)$/,z4],[/^(?:reset|revert|restore|default)$/,hE],[/^(?:apply|commit|confirm|accept)$/,n0],[/^(?:cancel|reject|discard)$/,hu],[/^(?:toggle|enable|disable|switch)$/,YE],[/^(?:next|forward)$/,ws],[/^(?:previous|prev|back)$/,S4],[/^(?:step)$/,pm],[/^(?:go|jump|seek)$/,om],[/^(?:trim|crop)$/,E4],[/^(?:insert|add|new|create|make)$/,Dn],[/^(?:select|pick)$/,du],[/^(?:list|inspect|info|get|query|state)$/,UC],[/^(?:convert|change)$/,dE],[/^(?:sort)$/,a0],[/^(?:filter)$/,A4],[/^(?:link)$/,oi],[/^(?:unlink)$/,nu],[/^(?:increase|grow|raise)$/,cu],[/^(?:decrease|shrink|lower)$/,uu],[/^(?:refresh|reload|update|sync)$/,r0],[/^(?:define|edit|modify|configure)$/,Ms],[/^(?:arrange|order|bring|send)$/,t0],[/^(?:snap)$/,qC],[/^(?:smooth|simplify)$/,d0],[/^(?:stroke|outline)$/,lE],[/^(?:fill)$/,_4],[/^(?:mask)$/,R1]],Em=[[/\b(?:heading|title)\b/,jC],[/\b(?:level|outline|tree)\b/,BC],[/\b(?:code)\b/,rC],[/\b(?:direction)\b/,Gx],[/\b(?:waypoints?|bends?)\b/,eg],[/\b(?:stats|statistics|performance)\b/,TC],[/\b(?:mixer)\b/,tu],[/\b(?:clipboard)\b/,iC],[/\b(?:cache)\b/,fm],[/\b(?:values?)\b/,N4],[/\b(?:autofill|series)\b/,Ux],[/\b(?:flash)\b/,QE],[/\b(?:painter)\b/,eE],[/\b(?:field|form)\b/,GE],[/\b(?:tab order)\b/,j1],[/\b(?:smart ?art|diagram)\b/,PC],[/\b(?:action button|button)\b/,L4],[/\b(?:pen)\b/,V4],[/\b(?:pencil)\b/,Ms],[/\b(?:highlighter)\b/,NC],[/\b(?:word)\b/,FE],[/\b(?:caret|cursor)\b/,qE],[/\b(?:distance|perimeter|area)\b/,Cu],[/\b(?:work area)\b/,z4],[/\b(?:brush|paint)\b/,w4],[/\b(?:gradient)\b/,ds],[/\b(?:transparen|opacity|blend)\b/,ds],[/\b(?:colou?rs?|swatch|palette)\b/,U4],[/\b(?:font|character|typograph|text|type)\b/,Tu],[/\b(?:para(graph)?)\b/,O1],[/\b(?:presets?|styles?)\b/,DE],[/\b(?:layers?)\b/,fu],[/\b(?:paths?|anchor|point|bezier|curve)\b/,d0],[/\b(?:camera)\b/,Fx],[/\b(?:track)\b/,$4],[/\b(?:clip|footage|sequence|timeline|multicam)\b/,mm],[/\b(?:markers?|bookmark)\b/,M4],[/\b(?:keys?|keyframe)\b/,pC],[/\b(?:channel)\b/,tu],[/\b(?:perspective|3d)\b/,b4],[/\b(?:grid|guide)\b/,T1],[/\b(?:frame|artboard)\b/,ps],[/\b(?:data|database|source)\b/,fm],[/\b(?:queue)\b/,j1],[/\b(?:project)\b/,vm],[/\b(?:comp(osition)?)\b/,fu],[/\b(?:playhead|time|duration)\b/,sC],[/\b(?:audio|sound|volume)\b/,ZE],[/\b(?:video)\b/,J4],[/\b(?:preferences|settings|options)\b/,o0],[/\b(?:shape|rectangle|ellipse|polygon)\b/,Eu],[/\b(?:light|lamp)\b/,HC],[/\b(?:solid)\b/,Ss],[/\b(?:null)\b/,mC],[/\b(?:adjustment)\b/,tu],[/\b(?:footage|media)\b/,mm],[/\b(?:folder)\b/,vm],[/\b(?:mosaic)\b/,AC],[/\b(?:gradient mesh|mesh)\b/,T1],[/\b(?:line|arrow)\b/,QC],[/\b(?:comment|note)\b/,i0],[/\b(?:page)\b/,l0],[/\b(?:cell|row|column)\b/,F4],[/\b(?:formula|function)\b/,h0],[/\b(?:symbol)\b/,oC],[/\b(?:effect|filter)\b/,P4],[/\b(?:selection)\b/,du]],Mu=cC,Tm=/^(?:insert|add|new|create|make)$/,xg=new Map;function sk(l){for(const[s,u]of Object.entries(l))xg.set(s,u)}function bu(l){var p,y,g,v,b;const s=xg.get(l.id);if(s)return s;const u=M=>M.replace(/([a-z])([A-Z])/g,"$1 $2").replace(/[._-]/g," ").toLowerCase(),c=u(l.id.split(".").pop()??"").split(" ")[0],f=((p=(l.title??"").trim().split(/\s+/)[0])==null?void 0:p.toLowerCase())??"",o=`${u(l.id)} ${(l.title??"").toLowerCase()}`;if(Tm.test(c)||Tm.test(f)){const M=`${u(l.id.split(".").pop()??"")} ${(l.title??"").toLowerCase()}`,z=(y=Em.find(([x])=>x.test(M)))==null?void 0:y[1];if(z)return z}return((g=ik.find(([M])=>M.test(c)||M.test(f)))==null?void 0:g[1])||(((v=Em.find(([M])=>M.test(o)))==null?void 0:v[1])??((b=lk.find(([M])=>M.test(o)))==null?void 0:b[1])??Mu)}function Nu(l){return Object.values(l.schema??{}).some(s=>s.required)}const rk=6,km=l=>typeof l=="string"?l:JSON.stringify(l);function uk(l,s){var u;return s!==void 0?km(s):l.default!==void 0?km(l.default):(u=l.enum)!=null&&u.length?l.required?String(l.enum[0]):"":l.type==="boolean"?"false":""}function ck(l,s){switch(l.type){case"number":case"integer":return s.trim()===""?void 0:Number(s);case"boolean":return s==="true";case"string":return s===""?void 0:s;default:if(s.trim()==="")return;try{return JSON.parse(s)}catch{return s}}}function ok({command:l,onRun:s,onClose:u,labels:c,values:f={},title:o}){const d=l.schema??{},[p,y]=w.useState(()=>Object.fromEntries(Object.entries(d).map(([C,N])=>[C,uk(N,f[C])]))),g=Object.entries(d),v=g.length>rk,b=([C,N])=>!v||N.required||f[C]!==void 0,M=g.filter(b),z=g.filter(C=>!b(C)),x=([C,N])=>{var $;const G=le=>y(Z=>({...Z,[C]:le})),J=`param-${C}`;return[h.jsxs("label",{htmlFor:J,title:N.description,children:[C,N.required?h.jsx("span",{title:c.required,children:" *"}):null]},`${C}-label`),($=N.enum)!=null&&$.length?h.jsxs("select",{id:J,className:"kui-field",value:p[C],onChange:le=>G(le.target.value),children:[N.required?null:h.jsx("option",{value:""}),N.enum.map(le=>h.jsx("option",{value:String(le),children:String(le)},String(le)))]},C):N.type==="boolean"?h.jsx("input",{id:J,type:"checkbox",checked:p[C]==="true",onChange:le=>G(String(le.target.checked))},C):h.jsx("input",{id:J,className:"kui-field",type:N.type==="number"||N.type==="integer"?"number":"text",value:p[C],placeholder:N.description,onChange:le=>G(le.target.value)},C)]},E=Object.entries(d).some(([C,N])=>N.required&&(p[C]??"").trim()===""),T=()=>{const C={};for(const[N,G]of Object.entries(d)){const J=ck(G,p[N]??"");J!==void 0&&(C[N]=J)}s(C)};return h.jsx(Un,{title:o??l.title,onClose:u,actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:u,children:c.cancel}),h.jsx(ua,{variant:"primary",disabled:E,onClick:T,"data-testid":"command-dialog-run",children:c.run})]}),children:h.jsxs("form",{onSubmit:C=>{C.preventDefault(),E||T()},children:[h.jsx("div",{className:"kui-param-grid",children:M.map(x)}),z.length?h.jsxs("details",{children:[h.jsx("summary",{children:c.more??"More options"}),h.jsx("div",{className:"kui-param-grid",children:z.map(x)})]}):null,h.jsx("button",{type:"submit",hidden:!0})]})})}function fk(l){const s=document.activeElement;return!s||s===l?!1:s instanceof HTMLInputElement||s instanceof HTMLTextAreaElement||s instanceof HTMLSelectElement||s instanceof HTMLElement&&s.isContentEditable}function dk({active:l,onText:s,onKey:u}){const c=w.useRef(null),f=w.useRef(!1);w.useEffect(()=>{if(!l)return;let d;const p=()=>{var v;d=void 0,document.hasFocus()&&!fk(c.current)&&((v=c.current)==null||v.focus({preventScroll:!0}))};p();const y=()=>{d!==void 0&&cancelAnimationFrame(d),d=requestAnimationFrame(p)},g=v=>{if(document.activeElement!==c.current)return;const b=v.target instanceof Element?v.target.closest("button"):null;b&&!b.disabled&&v.preventDefault()};return window.addEventListener("pointerup",y),window.addEventListener("mousedown",g,!0),()=>{window.removeEventListener("pointerup",y),window.removeEventListener("mousedown",g,!0),d!==void 0&&cancelAnimationFrame(d)}},[l]);const o=()=>{var p;const d=((p=c.current)==null?void 0:p.value)??"";c.current&&(c.current.value=""),d&&s(d)};return h.jsx("textarea",{ref:c,className:"kui-text-sink","aria-hidden":"true",tabIndex:-1,autoCapitalize:"off",autoComplete:"off",autoCorrect:"off",spellCheck:!1,onCompositionStart:()=>{f.current=!0},onCompositionEnd:()=>{f.current=!1,o()},onInput:()=>{f.current||o()},onKeyDown:d=>{if(f.current||d.nativeEvent.isComposing||d.key==="Process")return;const p=d.metaKey||d.ctrlKey;d.key.length===1&&!p||u(d)&&d.preventDefault()},"data-testid":"kit-text-sink"})}function Cg(l,s){const u=[s,s.split("-")[0],"en-US"].map(c=>{var f;return l[c]??((f=Object.entries(l).find(([o])=>o.split("-")[0]===c))==null?void 0:f[1])}).filter(c=>!!c);return(c,f)=>{var d;const o=((d=u.find(p=>c in p))==null?void 0:d[c])??c;return f?o.replace(/\{(\w+)\}/g,(p,y)=>y in f?String(f[y]):p):o}}const hk=new Set(["Cmd+N","Cmd+W","Cmd+O","Cmd+P","Cmd+Q","Cmd+,","Cmd+S","Cmd+Shift+S","Cmd+T","Cmd+."]),mk=hk,Am={"[":"BracketLeft","]":"BracketRight",",":"Comma",".":"Period","/":"Slash","\\":"Backslash","-":"Minus","=":"Equal",";":"Semicolon","'":"Quote","`":"Backquote"};function Eg(){return typeof navigator<"u"&&/Mac|iPhone|iPad/i.test(navigator.platform)}function jm(l,s,u=Eg(),c=!1){const f=l.split("+"),o=f.length>1&&f[f.length-1]===""?"+":f.pop()??"",d=new Set(f.filter(Boolean)),p=d.has("Cmd"),y=u?s.metaKey:s.ctrlKey,g=u?s.ctrlKey:!1;return p!==y||d.has("Ctrl")!==g||d.has("Shift")!==s.shiftKey||d.has("Alt")!==s.altKey?!1:/^[A-Za-z]$/.test(o)?s.code===`Key${o.toUpperCase()}`:/^[0-9]$/.test(o)?s.code===`Digit${o}`:Am[o]?s.code===Am[o]:o==="Delete"?s.key==="Delete"||!c&&s.key==="Backspace":s.key===o}function vk(l){return!l||mk.has(l)?!1:l.includes("+")||/^(Delete|Backspace|PageUp|PageDown|F[0-9]{1,2})$/.test(l)}function pk(l,s,u=Eg()){const c=l.filter(f=>vk(f.shortcut));return c.find(f=>jm(f.shortcut,s,u,!0))??c.find(f=>jm(f.shortcut,s,u))}const yk=4,Dt={id:"Hand",cursor:"grab",begin:l=>{let s={x:l.clientX,y:l.clientY};return{move:(u,{viewport:c})=>{c.panBy(u.clientX-s.x,u.clientY-s.y),s={x:u.clientX,y:u.clientY}}}}},gk={id:"Zoom",cursor:"zoom-in",begin:l=>({end:(s,{viewport:u})=>{Math.hypot(s.clientX-l.clientX,s.clientY-l.clientY)>yk||u.zoomTo(u.view.zoom*(s.alt?.5:2),s.clientX,s.clientY)}})},b1=8e6,Mk=33554432,Nm=8192,bk=[.5,.25,0],Om=32,wk=.01,Sk=64,Lt=8;function Rm(l,s,u,c){const f=(d,p)=>({pinned:!1,off:s,s0:d,s1:u,d0:p,d1:s+u/c});if(l<=0)return[f(0,s)];const o=Math.min(u,l*c);return[{pinned:!0,off:0,s0:0,s1:o,d0:0,d1:o/c},f(o,l+s)].filter(d=>d.s1>d.s0&&d.d1>d.d0)}function w1(l,s,u,c){const f=[];for(const o of Rm(s.top,l.y,c,l.zoom))for(const d of Rm(s.left,l.x,u,l.zoom))f.push({pinX:d.pinned,pinY:o.pinned,offX:d.off,offY:o.off,clip:{x0:d.s0,y0:o.s0,x1:d.s1,y1:o.s1},area:{x0:d.d0,y0:o.d0,x1:d.d1,y1:o.d1}});return f}function Lm(l,s,u){return new ImageData(new Uint8ClampedArray(l.buffer,l.byteOffset,l.byteLength),s,u)}function eu(l,s,u){return Math.min(u,Math.max(s,l))}function Dm(l){return Math.min(Sk,Math.max(wk,l))}function zk(l){const s=document.createElement("canvas");s.width=Lt*2,s.height=Lt*2;const u=s.getContext("2d");return u?(u.fillStyle="#ffffff",u.fillRect(0,0,Lt*2,Lt*2),u.fillStyle="#e8e8ec",u.fillRect(0,0,Lt,Lt),u.fillRect(Lt,Lt,Lt,Lt),l.createPattern(s,"repeat")):null}class xk{constructor(s,u,c,f,o=!0,d=()=>{}){sa(this,"view",{zoom:1,x:0,y:0});sa(this,"decorate",null);sa(this,"frames",[]);sa(this,"held",null);sa(this,"pattern",null);sa(this,"settle");sa(this,"moves",0);sa(this,"rendering",!1);sa(this,"renderAgain",!1);sa(this,"pendingDamage",null);sa(this,"disposed",!1);sa(this,"generation",0);sa(this,"failed",!1);sa(this,"fitted",null);sa(this,"laidOut",null);sa(this,"panBounds",null);this.canvas=s,this.doc=u,this.backdrop=c,this.onChange=f,this.framed=o,this.onRender=d}invalidate(){this.pendingDamage=null,this.drop(),this.rendering&&(this.renderAgain=!0)}drop(){this.generation+=1}dispose(){var s;(s=this.settle)==null||s.call(this),this.settle=void 0,this.disposed=!0,this.frames=[]}get size(){return{width:this.canvas.clientWidth,height:this.canvas.clientHeight,dpr:window.devicePixelRatio||1}}get pins(){const s=this.doc.pinned;return{left:Math.max(0,(s==null?void 0:s.left)??0),top:Math.max(0,(s==null?void 0:s.top)??0)}}toScreen(s,u){const{left:c,top:f}=this.pins,o=this.shown,{zoom:d}=o;return{x:(s<c?s:s-o.x)*d,y:(u<f?u:u-o.y)*d}}toImage(s,u){const c=this.canvas.getBoundingClientRect(),{left:f,top:o}=this.pins,d=this.shown,p=(s-c.left)/d.zoom,y=(u-c.top)/d.zoom;return{x:p<f?p:d.x+p,y:y<o?y:d.y+y}}fit(){this.fitArea({x0:0,y0:0,x1:this.doc.width,y1:this.doc.height})}fitArea(s){const{width:u,height:c}=this.size,f=s.x1-s.x0,o=s.y1-s.y0;if(!u||!c||f<=0||o<=0)return;const d=Dm(Math.min((u-Om*2)/f,(c-Om*2)/o));this.setView({zoom:d,x:s.x0+f/2-u/2/d,y:s.y0+o/2-c/2/d},{...s})}resized(){const{width:s,height:u}=this.size,c=this.laidOut;if(!s||!u||(this.laidOut={width:s,height:u},!c||c.width===s&&c.height===u))return;if(this.fitted){this.fitArea(this.fitted);return}const{left:f,top:o}=this.pins;if(f>0||o>0)return;const{zoom:d}=this.view,p=this.panBounds,y=(g,v)=>v!==void 0&&Math.abs(g-v)<1e-6;this.setView({zoom:d,x:y(this.view.x,p==null?void 0:p.x0)?this.view.x:this.view.x+(c.width-s)/2/d,y:y(this.view.y,p==null?void 0:p.y0)?this.view.y:this.view.y+(c.height-u)/2/d})}zoomTo(s,u,c){const f=this.canvas.getBoundingClientRect(),o=u??f.left+f.width/2,d=c??f.top+f.height/2,p=this.toImage(o,d),y=Dm(s),{left:g,top:v}=this.pins;this.setView({zoom:y,x:p.x<g?this.view.x:p.x-(o-f.left)/y,y:p.y<v?this.view.y:p.y-(d-f.top)/y})}panTo(s,u){this.setView({...this.view,x:s,y:u})}panBy(s,u){this.setView({...this.view,x:this.view.x-s/this.view.zoom,y:this.view.y-u/this.view.zoom})}setPanBounds(s){const u=this.panBounds;u===s||u&&s&&u.x0===s.x0&&u.y0===s.y0&&u.x1===s.x1&&u.y1===s.y1||(this.panBounds=s?{...s}:null,this.setView(this.view,this.fitted))}setView(s,u=null){this.moves+=1,this.fitted=u;const{left:c,top:f}=this.pins,o=this.shown,d=this.panBounds,{width:p,height:y}=this.size;if(d&&p>0&&y>0){const g=(v,b,M,z)=>z>=M-b?(b+M-z)/2:Math.max(b,Math.min(M-z,v));s={...s,x:g(s.x,d.x0,d.x1,p/s.zoom),y:g(s.y,d.y0,d.y1,y/s.zoom)}}if(this.view={zoom:s.zoom,x:c>0?Math.max(0,s.x):s.x,y:f>0?Math.max(0,s.y):s.y},s=this.view,this.schedule(),s.zoom===o.zoom&&this.frames.length&&!this.covers(s)){this.held=o;return}this.held=null,this.draw(),this.onChange(s,null)}get shown(){return this.held??this.view}release(){!this.held||this.disposed||(this.held=null,this.draw(),this.onChange(this.view,null))}covers(s){const{width:u,height:c}=this.size;return!u||!c?!0:w1(s,this.pins,u,c).every(f=>{const o=Math.max(0,f.area.x0),d=Math.max(0,f.area.y0),p=Math.min(this.doc.width,f.area.x1),y=Math.min(this.doc.height,f.area.y1);if(p<=o||y<=d)return!0;const g=this.frames.find(v=>v.pinX===f.pinX&&v.pinY===f.pinY);return!!g&&g.x<=o+.5&&g.y<=d+.5&&g.x+g.width>=p-.5&&g.y+g.height>=y-.5})}schedule(){if(this.settle!==void 0||this.disposed)return;const s=()=>{this.settle=void 0,this.render()};if(window.requestAnimationFrame){const u=window.requestAnimationFrame(s);this.settle=()=>window.cancelAnimationFrame(u)}else{const u=window.setTimeout(s,16);this.settle=()=>window.clearTimeout(u)}}async render(){var o;if((o=this.settle)==null||o.call(this),this.settle=void 0,this.disposed)return!1;if(this.rendering)return this.renderAgain=!0,!1;this.rendering=!0;const s=this.generation,u=this.moves;let c=!1;try{c=await this.renderNow(s),c&&(this.failed=!1,this.onRender(null))}catch(d){!this.disposed&&s===this.generation&&u===this.moves&&(this.failed=!0,this.onRender(d))}finally{this.rendering=!1}if(u!==this.moves&&(this.renderAgain=!0),!c&&!this.renderAgain&&this.release(),this.renderAgain&&!this.disposed)return this.renderAgain=!1,this.render();const f=this.pendingDamage;return this.pendingDamage=null,f&&!this.disposed&&await this.renderArea(f),c}async patch(s){if(this.disposed)return!1;if(this.rendering){const u=this.pendingDamage;return this.pendingDamage=u?{x0:Math.min(u.x0,s.x0),y0:Math.min(u.y0,s.y0),x1:Math.max(u.x1,s.x1),y1:Math.max(u.y1,s.y1)}:s,!1}return this.renderArea(s)}async renderNow(s){const{width:u,height:c,dpr:f}=this.size;if(!u||!c)return!1;const o=performance.now(),d=this.view,p=[];let y=0,g=0;for(const b of w1(d,this.pins,u,c)){const M=await this.renderPane(b,f);M&&(p.push(M),y=Math.max(y,M.bitmap.width),g+=M.bitmap.height)}if(this.disposed||s!==this.generation)return!1;this.frames=p,this.held=d.zoom===this.view.zoom&&!this.covers(this.view)?d:null;const v=Math.round(performance.now()-o);return this.draw(),p.length&&this.onChange(this.shown,{renderMs:v,frameWidth:y,frameHeight:g}),!0}async renderPane(s,u){var E;const c=this.view.zoom*u,f=T=>{const C=s.pinX?0:(s.area.x1-s.area.x0)*T,N=s.pinY?0:(s.area.y1-s.area.y0)*T;return{x0:Math.max(0,Math.floor(s.area.x0-C)),y0:Math.max(0,Math.floor(s.area.y0-N)),x1:Math.min(this.doc.width,Math.ceil(s.area.x1+C)),y1:Math.min(this.doc.height,Math.ceil(s.area.y1+N))}},o=T=>(T.x1-T.x0)*(T.y1-T.y0)*Math.min(1,c)**2*Math.max(1,c)**2<=b1,{x0:d,y0:p,x1:y,y1:g}=bk.map(f).find(T=>o(T))??f(0);if(y<=d||g<=p)return null;let v,b,M,z;if(c<1){let T=Math.max(1,Math.floor(1/c));for(;(y-d)/T*((g-p)/T)>b1;)T+=1;M=Math.ceil((y-d)/T),z=Math.ceil((g-p)/T),b=await this.doc.renderArea(d,p,d+M*T,p+z*T,M,z),v={x:d,y:p,width:M*T,height:z*T,scale:1/T}}else{let T=c;const C=(y-d)*(g-p)*T*T,N=f(0),G=Math.max(b1,Math.min(Mk,(N.x1-N.x0)*(N.y1-N.y0)*c*c));C>G&&(T=Math.max(1,T*Math.sqrt(G/C))),T=Math.max(1,Math.min(T,Nm/(y-d),Nm/(g-p))),M=Math.max(1,Math.ceil((y-d)*T)),z=Math.max(1,Math.ceil((g-p)*T)),b=await this.doc.render(d,p,T,M,z),v={x:d,y:p,width:M/T,height:z/T,scale:T}}const x=document.createElement("canvas");return x.width=M,x.height=z,(E=x.getContext("2d"))==null||E.putImageData(Lm(b,M,z),0,0),{bitmap:x,...v,pinX:s.pinX,pinY:s.pinY}}async renderArea(s){if(this.disposed)return!1;const u=this.frames;if(!u.length||this.rendering||this.failed)return this.render();const c=u.flatMap(g=>{const v=g.bitmap.width/g.width,b=g.bitmap.height/g.height,M=eu(Math.floor((s.x0-g.x)*v),0,g.bitmap.width),z=eu(Math.floor((s.y0-g.y)*b),0,g.bitmap.height),x=eu(Math.ceil((s.x1-g.x)*v),0,g.bitmap.width),E=eu(Math.ceil((s.y1-g.y)*b),0,g.bitmap.height);return x>M&&E>z?[{frame:g,sx:v,sy:b,px0:M,py0:z,width:x-M,height:E-z}]:[]});if(!c.length)return!1;const f=performance.now(),o=this.generation,d=[];try{for(const{frame:g,sx:v,sy:b,px0:M,py0:z,width:x,height:E}of c){const T=Math.round(1/g.scale);d.push(g.scale<1?await this.doc.renderArea(g.x+M*T,g.y+z*T,g.x+(M+x)*T,g.y+(z+E)*T,x,E):await this.doc.render(g.x+M/v,g.y+z/b,g.scale,x,E))}}catch(g){return!this.disposed&&o===this.generation&&this.frames===u&&(this.failed=!0,this.onRender(g)),!1}if(this.disposed||o!==this.generation)return!1;if(this.frames!==u)return this.render();c.forEach(({frame:g,px0:v,py0:b,width:M,height:z},x)=>{var E;return(E=g.bitmap.getContext("2d"))==null?void 0:E.putImageData(Lm(d[x],M,z),v,b)});const p=Math.round(performance.now()-f);this.draw();const y=c.reduce((g,v)=>v.width*v.height>g.width*g.height?v:g);return this.onChange(this.shown,{renderMs:p,frameWidth:y.width,frameHeight:y.height}),this.onRender(null),!0}setBackdrop(s){s===this.backdrop||this.disposed||(this.backdrop=s,this.draw())}draw(){const{width:s,height:u,dpr:c}=this.size,f=Math.round(s*c),o=Math.round(u*c);(this.canvas.width!==f||this.canvas.height!==o)&&(this.canvas.width=f,this.canvas.height=o);const d=this.canvas.getContext("2d");if(!d)return;const p=this.shown,{zoom:y}=p;d.setTransform(c,0,0,c,0,0),d.fillStyle=this.backdrop,d.fillRect(0,0,s,u);const g=w1(p,this.pins,s,u);for(const v of g){d.save(),g.length>1&&(d.beginPath(),d.rect(v.clip.x0,v.clip.y0,v.clip.x1-v.clip.x0,v.clip.y1-v.clip.y0),d.clip());const b=(x,E)=>({x:(x-v.offX)*y,y:(E-v.offY)*y}),M=b(0,0);this.framed&&(d.shadowColor="rgba(15, 15, 30, 0.12)",d.shadowBlur=12,this.pattern??(this.pattern=zk(d)),d.fillStyle=this.pattern??"#ffffff",d.fillRect(M.x,M.y,this.doc.width*y,this.doc.height*y),d.shadowBlur=0);const z=this.frames.find(x=>x.pinX===v.pinX&&x.pinY===v.pinY);if(z){d.imageSmoothingEnabled=y<1,d.imageSmoothingQuality="high";const x=b(z.x,z.y);d.drawImage(z.bitmap,x.x,x.y,z.width*y,z.height*y)}this.decorate&&(d.save(),this.decorate(d,b,{zoom:y,x:v.offX,y:v.offY}),d.restore()),d.restore()}}sample(s,u){var v;const c=this.toImage(s,u),{left:f,top:o}=this.pins,d=this.frames.find(b=>b.pinX===c.x<f&&b.pinY===c.y<o);if(!d)return null;const p=Math.floor((c.x-d.x)/d.width*d.bitmap.width),y=Math.floor((c.y-d.y)/d.height*d.bitmap.height);if(p<0||y<0||p>=d.bitmap.width||y>=d.bitmap.height)return null;const g=(v=d.bitmap.getContext("2d"))==null?void 0:v.getImageData(p,y,1,1).data;return g?[g[0],g[1],g[2]]:null}}const Ck="#f3f3f6";function Hm(){return getComputedStyle(document.documentElement).getPropertyValue("--kit-canvas").trim()||Ck}const Ek=.01,Tk=100;function kk(l,s=1){return l.pointerType!=="pen"?1:l.pressure>0?l.pressure:s}function ii(l,s,u=1){const c=s.toImage(l.clientX,l.clientY),f=s.toScreen(c.x,c.y);return{x:c.x,y:c.y,pressure:kk(l,u),clientX:l.clientX,clientY:l.clientY,canvasX:f.x,canvasY:f.y,shift:l.shiftKey,alt:l.altKey,meta:l.metaKey||l.ctrlKey}}function Ak(l,s){const u=(c,f)=>{const o=l.current,d=s.current,p=o==null?void 0:o.getContext("2d");if(!o||!d||!p)return;const y=window.devicePixelRatio||1,g=Math.round(o.clientWidth*y),v=Math.round(o.clientHeight*y);(o.width!==g||o.height!==v)&&(o.width=g,o.height=v),p.setTransform(y,0,0,y,0,0),c&&p.clearRect(0,0,o.clientWidth,o.clientHeight),p.save(),f(p,(b,M)=>d.toScreen(b,M)),p.restore()};return{draw:c=>u(!0,c),add:c=>u(!1,c),clear:()=>{var f;const c=l.current;(f=c==null?void 0:c.getContext("2d"))==null||f.clearRect(0,0,c.width,c.height)}}}function jk({doc:l,change:s,repaint:u,tool:c,onView:f,onRender:o,viewMemory:d,initialArea:p=null,panBounds:y=null,decorate:g=null,animated:v=!1,spacePans:b=!0,framed:M=!0,children:z,ref:x}){const E=w.useRef(null),T=w.useRef(null),C=w.useRef(null),N=w.useRef(null),[G,J]=w.useState(!1),$=w.useRef({doc:l,onView:f,onRender:o,initialArea:p,panBounds:y});$.current={doc:l,onView:f,onRender:o,initialArea:p,panBounds:y};const le=Ak(T,C);w.useEffect(()=>{const D=E.current;if(!D)return;let L=d.current!=null;const P=new xk(D,l,Hm(),(ye,te)=>{L&&(d.current=ye),$.current.onView({...ye,width:D.clientWidth,height:D.clientHeight},te)},M,ye=>{var te,oe;$.current.doc===l&&((oe=(te=$.current).onRender)==null||oe.call(te,ye))});C.current=P,d.current&&(P.view={...d.current}),P.setPanBounds($.current.panBounds);const re=new ResizeObserver(()=>{if(!L&&D.clientWidth>0&&D.clientHeight>0){L=!0;const ye=$.current.initialArea;ye?P.fitArea(ye):P.fit()}L&&P.resized(),P.render()});re.observe(D);const pe=ye=>{ye.preventDefault(),ye.ctrlKey||ye.metaKey?P.zoomTo(P.view.zoom*Math.exp(-ye.deltaY*Ek),ye.clientX,ye.clientY):P.panBy(-ye.deltaX,-ye.deltaY)};D.addEventListener("wheel",pe,{passive:!1});const I=typeof MutationObserver>"u"?null:new MutationObserver(()=>P.setBackdrop(Hm()));return I==null||I.observe(document.documentElement,{attributes:!0,attributeFilter:["style","data-color-scheme","data-brand","class"]}),()=>{I==null||I.disconnect(),re.disconnect(),D.removeEventListener("wheel",pe),P.dispose(),C.current=null}},[l,M,d]),w.useEffect(()=>{var D;return(D=C.current)==null?void 0:D.setPanBounds(y)},[l,y]),w.useEffect(()=>{const D=C.current;D&&(s.damage||D.invalidate(),(s.damage?D.patch(s.damage):D.render()).then(L=>{L&&le.clear()}))},[s]);const Z=w.useRef((u==null?void 0:u.tick)??0);w.useEffect(()=>{const D=C.current;!D||!u||u.tick===Z.current||(Z.current=u.tick,D.invalidate(),u.damage?D.renderArea(u.damage):D.render())},[u]),w.useEffect(()=>{const D=C.current;if(!D||(D.decorate=g,D.draw(),!v||!g))return;const L=window.setInterval(()=>D.draw(),Tk);return()=>window.clearInterval(L)},[v,g,l]),w.useEffect(()=>{if(!b)return;const D=re=>re instanceof HTMLInputElement||re instanceof HTMLTextAreaElement,L=re=>{re.code==="Space"&&!D(re.target)&&J(!0)},P=re=>{re.code==="Space"&&J(!1)};return window.addEventListener("keydown",L),window.addEventListener("keyup",P),()=>{window.removeEventListener("keydown",L),window.removeEventListener("keyup",P)}},[b]),w.useImperativeHandle(x,()=>({view:()=>{const D=C.current,L=E.current;return D&&L?{...D.view,width:L.clientWidth,height:L.clientHeight}:null},fit:()=>{var D;return(D=C.current)==null?void 0:D.fit()},show:D=>{var L;return(L=C.current)==null?void 0:L.fitArea(D)},zoomTo:D=>{var L;return(L=C.current)==null?void 0:L.zoomTo(D)},zoomBy:D=>{const L=C.current;L&&L.zoomTo(L.view.zoom*D)},panTo:(D,L)=>{var P;return(P=C.current)==null?void 0:P.panTo(D,L)},retryRender:async()=>{var L;const D=await((L=C.current)==null?void 0:L.render())??!1;return D&&le.clear(),D}}),[]);const ie=()=>C.current?{viewport:C.current,overlay:le}:null,se=w.useRef(1),ae=D=>{const L=ie();if(!L||D.button===2)return;D.preventDefault();const P=D.currentTarget.closest("[tabindex]");P&&document.activeElement!==P&&P.focus({preventScroll:!0}),D.currentTarget.setPointerCapture(D.pointerId);const re=G||D.button===1?Dt:c,pe=ii(D,L.viewport);se.current=pe.pressure,N.current=re.begin(pe,L)||null},de=D=>{var re,pe,I,ye;const L=ie(),P=N.current;if(L&&((re=c.track)==null||re.call(c,ii(D,L.viewport),L)),L&&!P&&!G&&D.buttons===0&&((pe=c.hover)==null||pe.call(c,ii(D,L.viewport),L)),!(!L||!(P!=null&&P.move)))for(const te of((ye=(I=D.nativeEvent).getCoalescedEvents)==null?void 0:ye.call(I))??[D.nativeEvent]){const oe=ii(te,L.viewport,se.current);se.current=oe.pressure,P.move(oe,L)}},q=D=>{var re;const L=ie(),P=N.current;N.current=null,L&&P&&((re=P.end)==null||re.call(P,ii(D,L.viewport,se.current),L))},ue=w.useRef(()=>{});ue.current=D=>{var re;const L=N.current;if(!L||D.key!=="Escape"||D.isComposing||D.metaKey||D.ctrlKey||D.altKey||D.shiftKey)return;N.current=null;const P=ie();P&&((re=L.cancel)==null||re.call(L,P)),le.clear(),D.preventDefault(),D.stopPropagation()},w.useEffect(()=>{const D=L=>ue.current(L);return window.addEventListener("keydown",D,!0),()=>window.removeEventListener("keydown",D,!0)},[]);const we=()=>{var P;const D=ie(),L=N.current;L&&(N.current=null,D&&((P=L.cancel)==null||P.call(L,D)),le.clear())};return h.jsxs("div",{className:"kui-canvas","data-testid":"kit-canvas",children:[h.jsx("canvas",{ref:E,className:"kui-canvas-surface",style:{cursor:G?Dt.cursor:c.cursor},onPointerDown:ae,onPointerMove:de,onPointerUp:q,onPointerCancel:we,onLostPointerCapture:we,onPointerLeave:()=>{var L;const D=ie();D&&!N.current&&((L=c.leave)==null||L.call(c,D))},onDoubleClick:D=>{var P;const L=ie();L&&((P=c.doubleClick)==null||P.call(c,ii({...D,clientX:D.clientX,clientY:D.clientY,pressure:1},L.viewport),L))},onContextMenu:D=>D.preventDefault(),"data-testid":"kit-canvas-surface"}),h.jsx("canvas",{ref:T,className:"kui-canvas-overlay","aria-hidden":"true"}),z]})}const su=new Set;function Nk(l){const s=(u,c,f)=>{su.has(s)||l(u,c,f)};return s}const Tg=new WeakMap;function kg(l){return[l,...(Tg.get(l)??[]).flatMap(kg)]}function _m(l,s){if(!l||!s)return l??s??null;const u=(c,f,o)=>{c.save();try{l(c,f,o)}finally{c.restore()}const d=kg(l).filter(p=>!su.has(p));for(const p of d)su.add(p);c.save();try{s(c,f,o)}finally{c.restore();for(const p of d)su.delete(p)}};return Tg.set(u,[l,s]),u}const hl="kit:";function Ou(l){return l.startsWith(hl)?`control:${l.slice(hl.length)}`:`command:${l}`}function Ag(l){const s=[],u=new Set;for(const c of l){for(let o=1;o<=c.path.length;o+=1){const d=`menu:${c.path.slice(0,o).join("/")}`;u.has(d)||(u.add(d),s.push({id:d,kind:"menu",label:c.path[o-1],parent:o>1?`menu:${c.path.slice(0,o-1).join("/")}`:null,menu:[]}))}if(c.command==="---")continue;const f=Ou(c.command);s.push({id:f,kind:f.startsWith("control:")?"control":"command",label:c.label,parent:c.path.length?`menu:${c.path.join("/")}`:null,menu:c.path})}return s}const jg=[{id:"action:undo",label:"undo"},{id:"action:redo",label:"redo"},{id:"action:agent",label:"askAgent"},{id:"action:mode",label:"modeMenu"},{id:"action:save",label:"save"},{id:"action:more",label:"more"}],Y1={tools:"tool",panels:"panel",tabs:"tab",groups:"group",controls:"control"};function Ok(l){if(!l)return null;const s=Object.keys(Y1).flatMap(u=>(l[u]??[]).map(c=>c.id));return new Set([...Ag(l.menus??[]).map(u=>u.id),...s,...jg.map(u=>u.id)])}function Ng({commands:l,declaration:s,engineTools:u,agent:c,t:f,phrase:o,config:d}){const p=[],y=new Set,g=(v,b,M,z,x=[])=>{if(y.has(v))return;y.add(v);const E=Oa(d,v,x);p.push({id:v,kind:b,label:M,parent:z,hidden:E.hidden,disabled:E.disabled})};for(const v of Ag((s==null?void 0:s.menus)??[]))g(v.id,v.kind,o(v.label),v.parent,v.menu);for(const v of l){for(let b=1;b<=v.menu.length;b+=1){const M=b>1?`menu:${v.menu.slice(0,b-1).join("/")}`:null;g(`menu:${v.menu.slice(0,b).join("/")}`,"menu",o(v.menu[b-1]),M)}g(`command:${v.id}`,"command",o(v.title),v.menu.length?`menu:${v.menu.join("/")}`:null,v.menu)}for(const v of u)g(`tool:${v.id}`,"tool",o(v.label),null);for(const v of Object.keys(Y1))for(const b of(s==null?void 0:s[v])??[])g(b.id,Y1[v],f(b.label),b.parent??null);for(const v of jg)(c||v.id!=="action:agent")&&g(v.id,"action",f(v.label),null);return p}const Rk=()=>!1,Ru=w.createContext(null),Lk=bg(B1,null,()=>{});function ya(){const l=w.useContext(Ru),s=(l==null?void 0:l.store)??Lk,u=w.useSyncExternalStore(s.subscribe,s.get);return{config:u,store:s,locale:(l==null?void 0:l.locale)??"en-US",declared:(l==null?void 0:l.declared)??null,state:(c,f)=>{var p;const o=c.startsWith("command:"),d=Oa(u,c,f??(o?(l==null?void 0:l.menuOf(c.slice(8)))??[]:[]));return o&&!d.hidden&&((p=l==null?void 0:l.sessionHidden)!=null&&p.call(l,c.slice(8)))?{...d,hidden:!0}:d},sessionHidden:(l==null?void 0:l.sessionHidden)??Rk,buttons:c=>Mg(u,c),press:(l==null?void 0:l.press)??(()=>{}),offerHide:(l==null?void 0:l.offerHide)??null,openCustomize:(l==null?void 0:l.openCustomize)??null,hide:(l==null?void 0:l.hide)??null,renderButtons:(l==null?void 0:l.renderButtons)??(()=>null)}}function Og({value:l,children:s}){return h.jsx(Ru.Provider,{value:l,children:h.jsx(Dk,{children:s})})}function Dk({children:l}){const s=w.useContext(Ru),u=ya(),{config:c}=u,f=w.useMemo(()=>({state:o=>u.state(o),renderExtras:(o,d)=>u.renderButtons(o,d),drawn:o=>{o.startsWith("menu:")||u.declared}}),[c,s]);return h.jsx(Sb,{elements:f,children:l})}const Um={bell:$x,check:n0,download:E1,eye:vs,flag:T4,help:tC,info:OC,link:oi,lock:gs,mail:GC,message:i0,plus:Dn,printer:s0,send:vE,settings:o0,share:pE,star:TE,upload:XE,x:hu},ul=new Map,Hk=32;function _k(l){if(!l)return;if(!l.startsWith("data:image/"))return Object.hasOwn(Um,l)?Um[l]:Ss;const s=ul.get(l);if(s)return ul.delete(l),ul.set(l,s),s;if(ul.size>=Hk){const c=ul.keys().next().value;c!==void 0&&ul.delete(c)}const u=(({size:c=16})=>h.jsx("img",{src:l,width:c,height:c,alt:"","aria-hidden":"true"}));return ul.set(l,u),u}function Lu({place:l,as:s}){const u=ya();return h.jsx(h.Fragment,{children:u.buttons(l).map(c=>{const f=DT(c,u.locale),o=_k(c.icon),d=`host:${c.id}`;return s==="menu"?h.jsx(Bt,{icon:o,label:f,shortcut:c.shortcut,disabled:c.disabled,onSelect:()=>u.press(c.id),uiId:d},c.id):s==="ribbon"?h.jsx(St,{icon:o,label:f,pressed:c.pressed,disabled:c.disabled,onClick:()=>u.press(c.id),"data-kit-ui-id":d},c.id):h.jsxs(ua,{variant:"ghost","aria-pressed":c.pressed,disabled:c.disabled,onClick:()=>u.press(c.id),"data-kit-ui-id":d,children:[o?h.jsx(o,{size:15,strokeWidth:na,"aria-hidden":"true"}):null,f]},c.id)})})}const Bm=new Set;function Uk(l,s){const u=new Map(l.map(M=>[M.id,M])),c=M=>{const z=new Set;for(let x=M.parent;x!==null&&!z.has(x);){z.add(x);const E=u.get(x);if(!E)return!1;if(E.hidden)return!0;x=E.parent}return!1},f=l.filter(M=>!M.hidden&&M.id!==gg&&!(M.kind==="command"&&M.parent===null)&&!c(M)),o=new Map(f.map(M=>[M.id,M])),d=new Map;for(const M of f){if(M.parent===null)continue;const z=d.get(M.parent);z?z.push(M):d.set(M.parent,[M])}const p=(M,z)=>{const x=new Set(z);x.add(M.id);const E=(d.get(M.id)??[]).filter(T=>x.has(T.id)?(Bm.has(T.id)||(Bm.add(T.id),console.warn(`[kit-editor] ${T.id} is its own ancestor in the declared elements`)),!1):!0).map(T=>p(T,x));return{element:M,children:E}},y=[],g=new Set;for(const M of f){if(g.has(M.id))continue;const z=[];let x=M;for(;x!==void 0;){const E=x;if(g.has(E.id)){for(const N of z)g.add(N);break}const T=z.indexOf(E.id);if(T!==-1){y.push(o.get(z[T]));for(const N of z)g.add(N);break}z.push(E.id);const C=E.parent!==null?o.get(E.parent):void 0;if(C===void 0){y.push(E);for(const N of z)g.add(N);break}x=C}}const v=s.trim().toLowerCase(),b=M=>{const z=M.children.map(b).filter(x=>x!==null);return v&&!M.element.label.toLowerCase().includes(v)&&!z.length?null:{element:M.element,children:z}};return y.map(M=>b(p(M,new Set))).filter(M=>M!==null)}function Bk({catalog:l,personal:s,labels:u,onSave:c,onClose:f}){const[o,d]=w.useState([...s]),[p,y]=w.useState(""),g=w.useMemo(()=>Uk(l,p),[l,p]),v=M=>d(z=>z.includes(M)?z.filter(x=>x!==M):[...z,M]),b=(M,z)=>{const x=o.includes(M.element.id);return h.jsxs("li",{children:[h.jsxs("label",{className:"kui-customize-row",children:[h.jsx("input",{type:"checkbox",checked:!x,disabled:z,onChange:()=>v(M.element.id),"data-element":M.element.id}),h.jsx("span",{children:M.element.label})]}),M.children.length?h.jsx("ul",{children:M.children.map(E=>b(E,z||x))}):null]},M.element.id)};return h.jsxs(Un,{title:u.title,onClose:f,actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{variant:"ghost",onClick:()=>d([]),"data-action":"restore",children:u.restore}),h.jsx("span",{style:{flex:1}}),h.jsx(ua,{variant:"ghost",onClick:f,children:u.cancel}),h.jsx(ua,{variant:"primary",onClick:()=>c(o),"data-action":"save",children:u.save})]}),children:[h.jsx("input",{className:"kui-field kui-customize-search",type:"search",placeholder:u.search,"aria-label":u.search,value:p,onChange:M=>y(M.target.value)}),h.jsx("ul",{className:"kui-customize-tree","data-testid":"kit-customize-tree",children:g.map(M=>b(M,!1))})]})}function Vk({message:l,title:s,retryLabel:u,onRetry:c}){return h.jsxs("div",{className:"kui-render-failure",role:"alert","data-testid":"kit-render-failure",children:[h.jsxs("div",{children:[h.jsx("strong",{children:s}),h.jsx("div",{className:"kui-muted",children:l})]}),h.jsx(ua,{onClick:c,children:u})]})}const Rg={"en-US":{undo:"Undo",redo:"Redo",askAgent:"Ask Agent",save:"Save",saved:"Saved",saveFailed:"Could not save",commandFailed:"The command failed",run:"Run",cancel:"Cancel",required:"Required",zoomOut:"Zoom out",zoomIn:"Zoom in",fit:"Fit",opening:"Opening…",openFailed:"This file could not be opened",renderFailed:"This view could not be rendered",retryRender:"Retry",unsaved:"Unsaved changes",fileChanged:"This file changed outside the editor, and you have unsaved edits.",keepMine:"Keep my edits",reloadFile:"Load the new version",noHost:"This editor runs inside a host, such as Kition.",selected:"{count} selected",moreOptions:"More options",menuBar:"Menu",ribbonScrollStart:"Scroll ribbon left",ribbonScrollEnd:"Scroll ribbon right",menusScrollStart:"Scroll menus left",menusScrollEnd:"Scroll menus right",optionsScrollStart:"Scroll tool options left",optionsScrollEnd:"Scroll tool options right",agentEdited:"Edited by the agent",hostEdited:"Edited by the app",agentLeaseHeld:"{name} is editing this part of the document, so the agent's edit was not made. Try again when they are done.",someone:"Someone",viewOnly:"View only",viewOnlyRefused:"This document is view only",commentOnly:"Can comment",commentOnlyRefused:"You can only comment on this document",more:"More",customize:"Customize interface…",customizeTitle:"Customize interface",customizeSearch:"Search",customizeRestore:"Restore defaults",customizeSave:"Save",customizeFailed:"Could not keep your customization",hideElement:"Hide",expandPanelGroup:"Expand panel group",collapsePanelGroup:"Collapse panel group",closePanel:"Close Panel",maximizeFrame:"Maximize Frame",restoreWorkspace:"Restore Workspace",panelMenu:"Panel menu",moreTabs:"More tabs",resizePanels:"Resize panels",colorPickerSquare:"Saturation and brightness",colorPickerHue:"Hue",colorPickerHex:"Hex color",railTwoColumns:"Show tools in two columns",railOneColumn:"Show tools in one column",transportControls:"Transport controls",levelMeter:"Audio levels",keyframeLane:"Keyframes",keyframeAt:"Keyframe at {time}",previewDialogOk:"OK",previewDialogCancel:"Cancel",previewDialogReset:"Reset",previewDialogPreview:"Preview",previewDialogPending:"Updating the preview…",previewDialogOff:"Preview is off: {error}",curveEditor:"Curve",curveEditorPoint:"Point {index}: {x}, {y}",colorWheel:"color wheel",colorWheelLightness:"{label} lightness",colorWheelOffset:"{label}: {x}, {y}",floatingPanelClose:"Close {title}",floatingPanelResize:"Resize",drawingIllustrations:"Illustrations",drawingShapes:"Shapes",drawingTextBox:"Text Box",drawingRect:"Rectangle",drawingRoundRect:"Rounded Rectangle",drawingEllipse:"Oval",drawingTriangle:"Triangle",drawingDiamond:"Diamond",drawingArrow:"Arrow",drawingStar:"Star",drawingLine:"Line",drawingShapeStyles:"Shape Styles",drawingFill:"Shape Fill",drawingNoFill:"No Fill",drawingOutline:"Shape Outline",drawingNoOutline:"No Outline",drawingWeight:"{value} pt",drawingArrange:"Arrange",drawingChangeShape:"Change Shape",drawingRotateRight:"Rotate Right 90°",drawingBringForward:"Bring Forward",drawingBringToFront:"Bring to Front",drawingSendBackward:"Send Backward",drawingSendToBack:"Send to Back",drawingGroup:"Group",drawingConnect:"Connect",drawingEffects:"Shape Effects",drawingShadowBottomRight:"Shadow: Offset Bottom Right",drawingShadowBottom:"Shadow: Offset Bottom",drawingShadowAround:"Shadow: Around",drawingNoShadow:"No Shadow",drawingGlow:"Glow",drawingNoGlow:"No Glow",drawingTransform:"Transform",drawingWarpArchUp:"Arch Up",drawingWarpArchDown:"Arch Down",drawingWarpCircle:"Circle",drawingWarpWave1:"Wave 1",drawingWarpWave2:"Wave 2",drawingWarpInflate:"Inflate",drawingWarpDeflate:"Deflate",drawingWarpSlantUp:"Slant Up",drawingWarpSlantDown:"Slant Down",drawingWarpTriangle:"Triangle Up",drawingWarpChevron:"Chevron Up",drawingWarpCurveUp:"Curve Up",drawingWarpCurveDown:"Curve Down",drawingWarpCanUp:"Can Up",drawingNoTransform:"No Transform",drawingGradientDown:"Gradient: Linear Down",drawingGradientRight:"Gradient: Linear Right",drawingGradientDiagonal:"Gradient: Linear Diagonal",drawingGradientCenter:"Gradient: From Center",drawingUngroup:"Ungroup",drawingDelete:"Delete",drawingShapeFormat:"Shape Format",chartInsert:"Chart",chartColumn:"Clustered Column",chartStackedColumn:"Stacked Column",chartBar:"Clustered Bar",chartLine:"Line",chartLineMarkers:"Line with Markers",chartArea:"Area",chartPie:"Pie",chartDoughnut:"Doughnut",chartScatter:"Scatter",chartRadar:"Radar",chartType:"Type",chartChangeType:"Change Chart Type",chartElements:"Chart Elements",chartTitle:"Chart Title",chartTitleText:"Chart Title",chartLegend:"Legend",chartLegend_top:"Top",chartLegend_bottom:"Bottom",chartLegend_left:"Left",chartLegend_right:"Right",chartLegendNone:"None",chartDataLabels:"Data Labels",chartGridlines:"Gridlines",chartAxisTitles:"Axis Titles",chartTrendline:"Trendline",chartTrendLinear:"Linear",chartTrendExp:"Exponential",chartTrendForecast:"Linear Forecast",chartTrendMovingAvg:"Two-Period Moving Average",chartErrorBars:"Error Bars",chartErrStdErr:"Standard Error",chartErrPercent:"Percentage",chartErrStdDev:"Standard Deviation",chartNone:"None",chartSeriesType:"Chart Type",chartSeriesTypeChart:"The chart's",chartSecondaryAxis:"Secondary Axis",chartAxisTitleText:"Axis Title",chartData:"Data",chartEditData:"Edit Data",chartSeriesName:"Series {n} name",chartCategoryName:"Category {n}",chartValue:"{series}, {category}",chartCategoryText:"Category {n}",chartSeriesText:"Series {n}",chartAddCategory:"Add Category",chartAddSeries:"Add Series",chartRemoveCategory:"Remove Category",chartRemoveSeries:"Remove Series",chartOk:"OK",chartFormat:"Format",chartFormatAxis:"Format Axis",chartAxis:"Axis",chartAxisValue:"Vertical (Value) Axis",chartAxisCategory:"Horizontal (Category) Axis",chartAxisMin:"Minimum",chartAxisMax:"Maximum",chartAxisMajor:"Major unit",chartAxisNumberFormat:"Number format",chartAxisAuto:"Auto",chartAxisShow:"Show axis",chartLabelPosition:"Label Position",chartLabel_bestFit:"Best Fit",chartLabel_ctr:"Center",chartLabel_inBase:"Inside Base",chartLabel_inEnd:"Inside End",chartLabel_outEnd:"Outside End",chartLabel_l:"Left",chartLabel_r:"Right",chartLabel_t:"Above",chartLabel_b:"Below",chartFormatSeries:"Format Series",chartSeries:"Series",chartLineWidth:"Line width (pt)",chartMarker:"Marker",chartMarker_auto:"Automatic",chartMarker_none:"None",chartMarker_circle:"Circle",chartMarker_dash:"Dash",chartMarker_diamond:"Diamond",chartMarker_dot:"Dot",chartMarker_plus:"Plus",chartMarker_square:"Square",chartMarker_star:"Star",chartMarker_triangle:"Triangle",chartMarker_x:"X",chartSmooth:"Smoothed line",inkTools:"Tools",inkPens:"Pens",inkSelect:"Select",inkPen:"Pen",inkPencil:"Pencil",inkHighlighter:"Highlighter",inkEraser:"Eraser",inkColor:"Ink Color",inkWeight:"Thickness",modeMenu:"Display mode",modeButton:"Display mode: {mode}",modeStepped:"Display mode: {mode} (showing {shown} to fit the window)",mode_menus:"Menus",mode_line:"Single line",mode_classic:"Classic",mode_focus:"Focus",focusBar:"Focus",exitFocus:"Exit focus",lineMore:"More: {group}"},"zh-CN":{undo:"撤销",redo:"重做",askAgent:"询问 Agent",save:"保存",saved:"已保存",saveFailed:"无法保存",commandFailed:"命令执行失败",run:"运行",cancel:"取消",required:"必填",zoomOut:"缩小",zoomIn:"放大",fit:"适应窗口",opening:"正在打开…",openFailed:"无法打开此文件",renderFailed:"无法渲染此视图",retryRender:"重试",unsaved:"有未保存的更改",fileChanged:"此文件在编辑器外被修改,而你有未保存的更改。",keepMine:"保留我的更改",reloadFile:"加载新版本",noHost:"此编辑器需在宿主(如 Kition)中运行。",selected:"已选 {count} 项",moreOptions:"更多选项",menuBar:"菜单",ribbonScrollStart:"向左滚动功能区",ribbonScrollEnd:"向右滚动功能区",menusScrollStart:"向左滚动菜单",menusScrollEnd:"向右滚动菜单",optionsScrollStart:"向左滚动工具选项",optionsScrollEnd:"向右滚动工具选项",agentEdited:"由 Agent 编辑",hostEdited:"由应用编辑",agentLeaseHeld:"{name} 正在编辑文档的这一部分,因此未执行 Agent 的编辑。请等其完成后再试。",someone:"有人",viewOnly:"仅查看",viewOnlyRefused:"此文档仅供查看",commentOnly:"可评论",commentOnlyRefused:"你只能评论此文档",more:"更多",customize:"自定义界面…",customizeTitle:"自定义界面",customizeSearch:"搜索",customizeRestore:"恢复默认",customizeSave:"保存",customizeFailed:"无法保存你的自定义设置",hideElement:"隐藏",expandPanelGroup:"展开面板组",collapsePanelGroup:"折叠面板组",closePanel:"关闭面板",maximizeFrame:"最大化框架",restoreWorkspace:"恢复工作区",panelMenu:"面板菜单",moreTabs:"更多选项卡",resizePanels:"调整面板大小",colorPickerSquare:"饱和度和明度",colorPickerHue:"色相",colorPickerHex:"十六进制颜色",railTwoColumns:"以两列显示工具",railOneColumn:"以一列显示工具",transportControls:"播放控件",levelMeter:"音频电平",keyframeLane:"关键帧",keyframeAt:"{time} 处的关键帧",previewDialogOk:"确定",previewDialogCancel:"取消",previewDialogReset:"重置",previewDialogPreview:"预览",previewDialogPending:"正在更新预览…",previewDialogOff:"预览已关闭:{error}",curveEditor:"曲线",curveEditorPoint:"点 {index}:{x},{y}",colorWheel:"色轮",colorWheelLightness:"{label}亮度",colorWheelOffset:"{label}:{x},{y}",floatingPanelClose:"关闭{title}",floatingPanelResize:"调整大小",drawingIllustrations:"插图",drawingShapes:"形状",drawingTextBox:"文本框",drawingRect:"矩形",drawingRoundRect:"圆角矩形",drawingEllipse:"椭圆",drawingTriangle:"三角形",drawingDiamond:"菱形",drawingArrow:"箭头",drawingStar:"星形",drawingLine:"直线",drawingShapeStyles:"形状样式",drawingFill:"形状填充",drawingNoFill:"无填充",drawingOutline:"形状轮廓",drawingNoOutline:"无轮廓",drawingWeight:"{value} 磅",drawingArrange:"排列",drawingChangeShape:"更改形状",drawingRotateRight:"向右旋转 90°",drawingBringForward:"上移一层",drawingBringToFront:"置于顶层",drawingSendBackward:"下移一层",drawingSendToBack:"置于底层",drawingGroup:"组合",drawingConnect:"连接",drawingEffects:"形状效果",drawingShadowBottomRight:"阴影:右下偏移",drawingShadowBottom:"阴影:下方偏移",drawingShadowAround:"阴影:四周",drawingNoShadow:"无阴影",drawingGlow:"发光",drawingNoGlow:"无发光",drawingTransform:"转换",drawingWarpArchUp:"上弯弧",drawingWarpArchDown:"下弯弧",drawingWarpCircle:"圆",drawingWarpWave1:"波形 1",drawingWarpWave2:"波形 2",drawingWarpInflate:"膨胀",drawingWarpDeflate:"收缩",drawingWarpSlantUp:"上斜",drawingWarpSlantDown:"下斜",drawingWarpTriangle:"正三角",drawingWarpChevron:"V 形:正",drawingWarpCurveUp:"上弯",drawingWarpCurveDown:"下弯",drawingWarpCanUp:"桶形:正",drawingNoTransform:"无转换",drawingGradientDown:"渐变:线性向下",drawingGradientRight:"渐变:线性向右",drawingGradientDiagonal:"渐变:线性对角",drawingGradientCenter:"渐变:从中心",drawingUngroup:"取消组合",drawingDelete:"删除",drawingShapeFormat:"形状格式",chartInsert:"图表",chartColumn:"簇状柱形图",chartStackedColumn:"堆积柱形图",chartBar:"簇状条形图",chartLine:"折线图",chartLineMarkers:"带数据标记的折线图",chartArea:"面积图",chartPie:"饼图",chartDoughnut:"圆环图",chartScatter:"散点图",chartRadar:"雷达图",chartType:"类型",chartChangeType:"更改图表类型",chartElements:"图表元素",chartTitle:"图表标题",chartTitleText:"图表标题",chartLegend:"图例",chartLegend_top:"顶部",chartLegend_bottom:"底部",chartLegend_left:"左侧",chartLegend_right:"右侧",chartLegendNone:"无",chartDataLabels:"数据标签",chartGridlines:"网格线",chartAxisTitles:"坐标轴标题",chartTrendline:"趋势线",chartTrendLinear:"线性",chartTrendExp:"指数",chartTrendForecast:"线性预测",chartTrendMovingAvg:"双周期移动平均",chartErrorBars:"误差线",chartErrStdErr:"标准误差",chartErrPercent:"百分比",chartErrStdDev:"标准偏差",chartNone:"无",chartSeriesType:"图表类型",chartSeriesTypeChart:"与图表相同",chartSecondaryAxis:"次坐标轴",chartAxisTitleText:"坐标轴标题",chartData:"数据",chartEditData:"编辑数据",chartSeriesName:"系列 {n} 名称",chartCategoryName:"类别 {n}",chartValue:"{series},{category}",chartCategoryText:"类别 {n}",chartSeriesText:"系列 {n}",chartAddCategory:"添加类别",chartAddSeries:"添加系列",chartRemoveCategory:"删除类别",chartRemoveSeries:"删除系列",chartOk:"确定",chartFormat:"格式",chartFormatAxis:"设置坐标轴格式",chartAxis:"坐标轴",chartAxisValue:"垂直(值)轴",chartAxisCategory:"水平(类别)轴",chartAxisMin:"最小值",chartAxisMax:"最大值",chartAxisMajor:"主要单位",chartAxisNumberFormat:"数字格式",chartAxisAuto:"自动",chartAxisShow:"显示坐标轴",chartLabelPosition:"标签位置",chartLabel_bestFit:"最佳匹配",chartLabel_ctr:"居中",chartLabel_inBase:"轴内侧",chartLabel_inEnd:"数据标签内",chartLabel_outEnd:"数据标签外",chartLabel_l:"靠左",chartLabel_r:"靠右",chartLabel_t:"靠上",chartLabel_b:"靠下",chartFormatSeries:"设置数据系列格式",chartSeries:"系列",chartLineWidth:"线条宽度(磅)",chartMarker:"数据标记",chartMarker_auto:"自动",chartMarker_none:"无",chartMarker_circle:"圆形",chartMarker_dash:"短划线",chartMarker_diamond:"菱形",chartMarker_dot:"圆点",chartMarker_plus:"加号",chartMarker_square:"正方形",chartMarker_star:"星形",chartMarker_triangle:"三角形",chartMarker_x:"X 形",chartSmooth:"平滑线",inkTools:"工具",inkPens:"笔",inkSelect:"选择",inkPen:"笔",inkPencil:"铅笔",inkHighlighter:"荧光笔",inkEraser:"橡皮擦",inkColor:"墨迹颜色",inkWeight:"粗细",modeMenu:"显示模式",modeButton:"显示模式:{mode}",modeStepped:"显示模式:{mode}(为适应窗口,显示为{shown})",mode_menus:"菜单",mode_line:"单行",mode_classic:"经典",mode_focus:"专注",focusBar:"专注",exitFocus:"退出专注",lineMore:"更多:{group}"}};function Lg(l,s){const u={...Rg};for(const[c,f]of Object.entries(l))u[c]={...u[c],...f};return Cg(u,s)}const Dg=new Set;function b0(l){return l instanceof Error?l.message:String(l)}function qk(l){var s;return Sg(l)||((s=l==null?void 0:l.data)==null?void 0:s.reason)==="read-only"}function $1(l,s,u){l.report?l.report(s,u):ui("error",s,b0(u))}const Vm={"edit.undo":"undo","edit.redo":"redo"};function Gk(l,s,u,c,f=p=>p,o,d={}){var te,oe;const p=w.useRef(d.report);p.current=d.report;const y=w.useCallback((k,j)=>p.current?p.current(k,j):ui("error",k,b0(j)),[]),{doc:g,change:v}=l,[b,M]=w.useState([]),[z,x]=w.useState(new Set),[E,T]=w.useState(null),C=w.useRef(o);C.current=o;const N=w.useCallback((k,j={})=>{var U;return T(k?{command:k,values:{...(U=C.current)==null?void 0:U.call(C,k),...j}}:null)},[]),G=w.useRef(l);G.current=l;const J=w.useSyncExternalStore(s.ui.subscribe,s.ui.get),$=d.history??null,[,le]=w.useState(0);w.useEffect(()=>$==null?void 0:$.subscribe(()=>le(k=>k+1)),[$]);const Z=w.useRef($);Z.current=$;const ie=s.readOnly===!0,se=l.comments??Dg,ae=w.useCallback(k=>ie&&yu(k,se),[se,ie]);w.useEffect(()=>{g&&g.commands().then(M)},[g]),w.useEffect(()=>{if(!g)return;let k=!1;return g.disabledCommands().catch(()=>[]).then(j=>{k||x(new Set(j))}),()=>{k=!0}},[v.revision,g]);const de=w.useCallback(async(k,j={})=>{const U=G.current.doc;if(!U)return null;const Q=ue.current.get(k);if(Q!=null&&Q.mutates&&Oa(s.ui.get(),`command:${k}`,Q.menu).denied||Q&&ae(Q))return null;try{return JSON.parse(await U.execute(k,j))}catch{return null}},[s,ae]),q=w.useMemo(()=>new Map(b.map(k=>[k.id,k])),[b]),ue=w.useRef(q);ue.current=q;const we=w.useCallback(async(k,j)=>{const U=q.get(k),Q=Z.current,ve=Q?Vm[k]:void 0;if(Q&&ve){if(Oa(s.ui.get(),`command:${k}`,U==null?void 0:U.menu).denied||Oa(s.ui.get(),`action:${ve}`).denied)return null;try{return JSON.stringify({done:await Q[ve]()!==!1})}catch(Se){return y(u("commandFailed"),Se),null}}if(!j&&U&&Nu(U)&&!Oa(s.ui.get(),`command:${k}`,U.menu).denied&&!ae(U))return N(U),null;try{return await G.current.run(k,j??{})}catch(Se){return ie&&qk(Se)?ui("info",u(se.size?"commentOnlyRefused":"viewOnlyRefused")):y(u("commandFailed"),Se),null}},[q,se,s,ie,ae,y,N,u]),D=$?$.canUndo():((te=g==null?void 0:g.info)==null?void 0:te.canUndo)??!1,L=$?$.canRedo():((oe=g==null?void 0:g.info)==null?void 0:oe.canRedo)??!1,P=w.useCallback((k,j)=>{const U=q.get(k);if(!U||Oa(J,`command:${k}`,U.menu).denied)return!1;const Q=$?Vm[k]:void 0;if(Q)return Q==="undo"?D:L;if(j.has(k)||ae(U))return!1;const ve=ie?wg(k,se):null;return ve===null||(ve==="undo"?D:L)},[q,L,D,se,$,ie,ae,J]),re=w.useCallback(k=>P(k,z),[z,P]),pe=w.useCallback(async k=>{const j=G.current.doc;if(!j)return!1;const U=await G.current.disabledCommands().catch(()=>null);return U!=null&&G.current.doc===j&&P(k,new Set(U))},[P]),I=w.useCallback(async()=>{try{await G.current.save(),ui("success",u("saved"))}catch(k){y(u("saveFailed"),k)}},[y,u]),ye=w.useCallback((k,j)=>{var U;Oa(s.ui.get(),`command:${k}`,(U=q.get(k))==null?void 0:U.menu).denied?we(k,j??{}):N(q.get(k)??null,j)},[q,s,we,N]);return{session:l,host:s,t:u,phrase:f,testId:c,commands:b,byId:q,enabled:re,enabledNow:pe,run:we,ask:ye,query:de,save:I,report:y,dialog:E,setDialog:N,comments:se,canUndo:D,canRedo:L}}const w0=w.createContext(null);function Yk({editor:l,tools:s=null,children:u}){const c=w.useMemo(()=>({editor:l,tools:s}),[l,s]),{host:f,byId:o,session:d}=l,p=w.useSyncExternalStore(f.ui.subscribe,f.ui.get),y=s==null?void 0:s.setDenied,g=f.readOnly===!0;w.useLayoutEffect(()=>{y==null||y(E=>g||Oa(p,`tool:${E}`).denied)},[p,g,y]);const v=w.useMemo(()=>Ok(f.declaration),[f]),b=w.useRef(d.doc);b.current=d.doc;const M=l.comments??Dg,z=w.useMemo(()=>({store:f.ui,locale:f.init.locale,menuOf:E=>{var T;return((T=o.get(E))==null?void 0:T.menu)??[]},declared:v,press:E=>{var T,C;return f.ui.action({id:E,document:{path:f.init.document.path,dirty:((T=b.current)==null?void 0:T.info.dirty)??!1,revision:((C=b.current)==null?void 0:C.info.revision)??0}})},offerHide:null,openCustomize:null,hide:null,renderButtons:(E,T)=>h.jsx(Lu,{place:E,as:T}),sessionHidden:M.size?E=>$T(o.get(E)??{id:E},M):void 0}),[o,M,v,f]),x=w.useRef(async()=>[]);return x.current=async()=>{const E=await d.commands(),T=s&&!s.tools.length?await d.tool("tools")??[]:(s==null?void 0:s.tools)??[];return Ng({commands:E,declaration:f.declaration,engineTools:T,agent:f.init.capabilities.includes("agent"),t:l.t,phrase:l.phrase,config:f.ui.get()})},w.useEffect(()=>{f.declaration&&f.peer.handle("ui/elements",()=>x.current())},[f]),h.jsx(w0.Provider,{value:c,children:h.jsx(Mb,{strings:l.t,children:h.jsx(Og,{value:z,children:u})})})}function Ne(){const l=w.useContext(w0);if(!l)throw new Error("useKitEditor outside KitEditorProvider");return l.editor}function ml(){return Ne().host.readOnly===!0}function mi(){var l;return((l=w.useContext(w0))==null?void 0:l.tools)??null}function Hg(l){const{offerHide:s}=ya();return s?u=>{u.preventDefault(),s(l,u.clientX,u.clientY)}:void 0}function si({command:l,params:s,ask:u,onRun:c,...f}){const o=Ne(),{enabled:d,byId:p,testId:y,phrase:g}=o,v=ya(),b=Hg(`command:${l}`);if(v.state(`command:${l}`).hidden)return null;const M=p.get(l);return h.jsx(St,{...f,label:f.label??g((M==null?void 0:M.title)??l),disabled:f.disabled||!d(l),onClick:()=>{u?o.ask(l):c&&s===void 0&&!(M&&Nu(M))?c(l):o.run(l,s)},onContextMenu:b??f.onContextMenu,"data-testid":`${y}-cmd-${l}`,"data-kit-ui-id":`command:${l}`})}function $k({tool:l,testId:s,...u}){const c=mi(),{testId:f}=Ne(),o=ya().state(`tool:${l}`);return o.hidden?null:h.jsx(St,{...u,pressed:(c==null?void 0:c.active)===l,disabled:u.disabled||!c||o.disabled,onClick:()=>{o.denied||(c==null||c.select(l))},"data-testid":s??`${f}-tool-${l}`,"data-kit-ui-id":`tool:${l}`})}function qm({icon:l,label:s,size:u="small",children:c,disabled:f,swatch:o,testId:d,primary:p,lineLabel:y}){const g=w.useContext(Ut),v=w.useContext(dl);if(g==="primary"&&!p)return null;const b=sg(g,u,l!=null,y,v.size);return h.jsx(xs,{trigger:({toggle:M,open:z})=>h.jsxs("span",{style:{display:"inline-flex",alignItems:"center"},"data-primary":p||void 0,children:[h.jsx(St,{icon:l,label:s,size:b,disabled:f,pressed:z,swatch:o,onClick:M,"data-testid":d,primary:p,lineLabel:y}),b!=="large"?h.jsx(ci,{size:11,strokeWidth:na,"aria-hidden":"true",style:{marginLeft:-4,opacity:.6},onClick:M}):null]}),children:h.jsx(Ut.Provider,{value:"full",children:h.jsx(dl.Provider,{value:zs,children:c})})})}function Xk({command:l,params:s,label:u,icon:c,ask:f,shortcut:o,checked:d,path:p,onRun:y}){const g=Ne(),{enabled:v,byId:b,testId:M,phrase:z}=g,x=ya(),E=Hg(`command:${l}`),T=p?x.state(`command:${l}`,p):null;if(x.state(`command:${l}`).hidden||T!=null&&T.hidden)return null;const C=b.get(l);return h.jsx("div",{onContextMenu:E,style:{display:"contents"},children:h.jsx(Bt,{icon:c,label:u??z((C==null?void 0:C.title)??l),shortcut:o===void 0?C==null?void 0:C.shortcut:o,disabled:!v(l)||!!(T!=null&&T.disabled),checked:d,onSelect:()=>{f?g.ask(l):y&&s===void 0&&!(C&&Nu(C))?y(l):g.run(l,s)},testId:`${M}-cmd-${l}`,uiId:`command:${l}`})})}function Kk({canvas:l,viewMemory:s,initialArea:u=null,panBounds:c=null,framed:f,animated:o,onView:d,testId:p,tool:y,decorate:g,decorateUnder:v,children:b}){const M=Ne(),z=mi(),x=w.useRef(null),{doc:E,change:T,failure:C,repaints:N}=M.session,[G,J]=w.useState(null),$=w.useSyncExternalStore(N.subscribe,N.get),{t:le}=M,Z=(z==null?void 0:z.decorate)??null,ie=w.useMemo(()=>_m(_m(v,Z),g),[g,v,Z]);return h.jsxs("div",{className:"kui-canvas-region","data-testid":p??`${M.testId}-canvas-region`,children:[C?h.jsxs("div",{className:"kui-message",role:"alert",children:[h.jsx("strong",{children:le("openFailed")}),h.jsx("span",{className:"kui-muted",children:C})]}):E?h.jsxs(jk,{ref:l,viewMemory:s??x,doc:E,change:T,repaint:$,tool:y??(z==null?void 0:z.canvasTool)??Dt,decorate:ie,spacePans:!(z!=null&&z.wantsText),initialArea:u,panBounds:c,framed:f,animated:o,onView:(se,ae)=>{var de;(de=z==null?void 0:z.viewZoom)==null||de.call(z,se.zoom),d==null||d(se,ae)},onRender:se=>J(se===null?null:{doc:E,message:b0(se)}),children:[b,(G==null?void 0:G.doc)===E?h.jsx(Vk,{message:G.message,title:le("renderFailed"),retryLabel:le("retryRender"),onRetry:()=>{var se;(se=l.current)==null||se.retryRender()}}):null]}):h.jsx("div",{className:"kui-message kui-muted",children:le("opening")}),z?h.jsx(dk,{active:z.wantsText,onText:z.typeText,onKey:se=>z.keyDown(se)}):null]})}const Gm=1.25,Ik=new Set(["checkbox","radio","button","submit","reset","range","color","file","image"]);function Ym(l){return l instanceof HTMLInputElement?!Ik.has(l.type):l instanceof HTMLSelectElement||l instanceof HTMLTextAreaElement&&!l.classList.contains("kui-text-sink")}function S0(){var o;const l=Ne(),s=ya(),u=l.host.readOnly===!0,c=u&&(((o=l.comments)==null?void 0:o.size)??0)>0,f=(d,p,y)=>{const g=s.state(`action:${d}`),v=s.state(`command:${p}`);return{hidden:g.hidden||v.hostHidden||u&&!c,disabled:!y||g.disabled||v.denied}};return{undo:f("undo","edit.undo",l.canUndo),redo:f("redo","edit.redo",l.canRedo),readOnly:u,commenting:c}}function Zk({before:l,mode:s}){const u=Ne(),c=ya(),{session:f,host:o,t:d,testId:p}=u,{dirty:y}=f,g=x=>c.state(`action:${x}`),{undo:v,redo:b,readOnly:M,commenting:z}=S0();return h.jsxs(h.Fragment,{children:[l,h.jsx(Lu,{place:"action",as:"action"}),M?h.jsx("span",{className:"kui-view-only","data-testid":`${p}-view-only`,"data-comment-only":z?"true":void 0,children:d(z?"commentOnly":"viewOnly")}):null,v.hidden?null:h.jsx(Ge,{icon:m0,label:d("undo"),disabled:v.disabled,onClick:()=>void u.run("edit.undo",{}),"data-testid":`${p}-undo`,"data-kit-ui-id":"action:undo"}),b.hidden?null:h.jsx(Ge,{icon:q4,label:d("redo"),disabled:b.disabled,onClick:()=>void u.run("edit.redo",{}),"data-testid":`${p}-redo`,"data-kit-ui-id":"action:redo"}),o.init.capabilities.includes("agent")&&!g("agent").hidden?h.jsxs(ua,{variant:"ghost",disabled:g("agent").disabled,onClick:()=>void o.openAgent(),"data-testid":`${p}-ask-agent`,"data-kit-ui-id":"action:agent",children:[h.jsx(f0,{size:15,strokeWidth:na,"aria-hidden":"true"}),d("askAgent")]}):null,s,g("save").hidden||M?null:h.jsxs(ua,{variant:"primary",disabled:!y||f.saving||g("save").disabled,onClick:()=>void u.save(),"data-testid":`${p}-save`,"data-kit-ui-id":"action:save",children:[h.jsx(X4,{size:15,strokeWidth:na,"aria-hidden":"true"}),d("save")]}),c.openCustomize&&!g("more").hidden?h.jsx(xs,{align:"end",trigger:({toggle:x,open:E})=>h.jsx(Ge,{icon:gC,label:d("more"),pressed:E,disabled:g("more").disabled,onClick:x,"data-testid":`${p}-more`,"data-kit-ui-id":"action:more"}),children:h.jsx(Bt,{label:d("customize"),onSelect:()=>{var x;return(x=c.openCustomize)==null?void 0:x.call(c)},testId:`${p}-customize`,uiId:"action:more"})}):null]})}function Fk({x:l,y:s,label:u,testId:c,onHide:f,onClose:o}){const d=w.useRef(null),[p,y]=w.useState(null);return w.useLayoutEffect(()=>{var b,M;const g=((b=d.current)==null?void 0:b.offsetWidth)??160,v=((M=d.current)==null?void 0:M.offsetHeight)??40;y({left:Math.max(4,Math.min(l,window.innerWidth-g-4)),top:Math.max(4,Math.min(s,window.innerHeight-v-4))})},[l,s]),w.useEffect(()=>{const g=v=>{v.key==="Escape"&&(v.preventDefault(),v.stopPropagation(),o())};return window.addEventListener("keydown",g,!0),()=>window.removeEventListener("keydown",g,!0)},[o]),h.jsx("div",{className:"kui-dialog-backdrop kui-hide-menu-backdrop",onPointerDown:o,children:h.jsx("div",{ref:d,className:"kui-popover kui-hide-menu",role:"menu",style:p??{left:l,top:s,visibility:"hidden"},onPointerDown:g=>g.stopPropagation(),children:h.jsx(Bt,{label:u,onSelect:f,testId:c})})})}function Qk({top:l,status:s,statusEnd:u,onStatusClick:c,canvas:f,zoom:o,onKeyDown:d,statusBar:p=!0,hiddenCommands:y,fileChangedBar:g=!0,frame:v,children:b}){var re,pe;const M=Ne(),z=mi(),{session:x,t:E,testId:T}=M,{dirty:C}=x,N=w.useContext(Ru),G=ya(),[J,$]=w.useState(null),[le,Z]=w.useState(null),ie=w.useCallback(()=>Z(null),[]),se=w.useRef(async()=>{});se.current=async I=>{try{await G.store.setPersonal(I)}catch(ye){$1(M,E("customizeFailed"),ye)}};const ae=w.useRef(()=>[]);ae.current=()=>Ng({commands:M.commands,declaration:M.host.declaration,engineTools:(z==null?void 0:z.tools)??[],agent:M.host.init.capabilities.includes("agent"),t:E,phrase:M.phrase,config:{...G.store.get(),personal:[]}});const{store:de}=G,q=de.customizable&&M.host.declaration!==null,ue=w.useMemo(()=>N&&q?{...N,offerHide:(I,ye,te)=>Z({id:I,x:ye,y:te}),openCustomize:()=>$(ae.current()),hide:I=>void se.current([...de.get().personal,I])}:N,[q,N,de]),we=I=>I.currentTarget.ownerDocument.querySelector(".kui-dialog-backdrop")!=null||I.target instanceof Element&&I.target.closest(".kui-dialog")!=null,D=I=>{!v||I.nativeEvent.isComposing||we(I)||v.keyDown(I)&&(I.preventDefault(),I.stopPropagation())},L=I=>{P(I);const ye=!I.metaKey&&!I.ctrlKey&&!I.altKey&&!I.shiftKey;v&&ye&&I.key==="Escape"&&!I.defaultPrevented&&!I.nativeEvent.isComposing&&!we(I)&&!Ym(I.target)&&v.escape()&&I.preventDefault()},P=I=>{if(we(I))return;const ye=I.target,te=Ym(ye);if(te&&!((I.metaKey||I.ctrlKey)&&!I.altKey&&I.key.toLowerCase()==="s"))return;const oe=ye instanceof HTMLTextAreaElement;if(oe&&I.defaultPrevented||!I.metaKey&&!I.ctrlKey&&!I.altKey&&!I.shiftKey&&(I.key===" "||I.key==="Enter")&&ye instanceof Element&&ye.matches('button, [role="menuitem"], input[type="checkbox"], input[type="radio"]'))return;if(!te&&!oe&&(z!=null&&z.keyDown(I))){I.preventDefault();return}if(!te&&(d!=null&&d(I))){I.preventDefault();return}const k=G.config.add.find(Se=>Se.shortcut&&!Se.disabled&&v5(Se.shortcut,I,ju()));if(k){I.preventDefault(),G.press(k.id);return}const j=I.metaKey||I.ctrlKey,U=I.key.toLowerCase();if(j&&U==="s"){I.preventDefault(),!G.state("action:save").denied&&!M.host.readOnly&&M.save();return}if(f!=null&&f.current&&j&&(U==="0"||U==="="||U==="+"||U==="-")){I.preventDefault(),U==="0"?f.current.fit():f.current.zoomBy(U==="-"?1/Gm:Gm);return}const Q=pk(y?M.commands.filter(Se=>!y(Se.id)):M.commands,I);if(Q&&M.enabled(Q.id)){I.preventDefault(),M.run(Q.id,{});return}if(Q&&!j&&!(I.key.length===1&&(z!=null&&z.toolForKey(I.key,I.shiftKey)))){I.preventDefault();const Se=Q.id;M.enabledNow(Se).then(Le=>Le?M.run(Se,{}):void 0);return}const ve=!j&&!I.altKey&&I.key.length===1&&!oe?z==null?void 0:z.toolForKey(I.key,I.shiftKey):null;ve&&!G.state(`tool:${ve}`).denied&&(I.preventDefault(),z==null||z.select(ve))};return h.jsx(Og,{value:ue,children:h.jsxs("div",{ref:v==null?void 0:v.ref,className:"kui-app","data-mode":v==null?void 0:v.mode,"data-chosen-mode":v==null?void 0:v.chosen,"data-density":v!=null&&v.touch?"touch":void 0,"data-view-only":(v==null?void 0:v.viewOnly)||void 0,onKeyDownCapture:D,onKeyDown:L,tabIndex:-1,children:[l,g&&x.conflict&&x.doc?h.jsxs("div",{className:"kui-file-changed",role:"alert","data-testid":`${T}-file-changed`,children:[h.jsx("span",{children:E("fileChanged")}),h.jsx(ua,{variant:"ghost",size:"sm",onClick:()=>void x.keepMine().catch(I=>$1(M,E("saveFailed"),I)),"data-testid":`${T}-keep-mine`,children:E("keepMine")}),h.jsx(ua,{variant:"primary",size:"sm",onClick:()=>x.reopen(),"data-testid":`${T}-reload`,children:E("reloadFile")})]}):null,b,p?h.jsxs(lT,{onClick:c?I=>!(I.target instanceof Element&&I.target.closest('button, input, select, [role="menuitem"]'))&&c():void 0,children:[s,C?h.jsx("span",{"data-testid":`${T}-unsaved`,children:E("unsaved")}):null,((re=x.editedBy)==null?void 0:re.by)==="agent"?h.jsxs("span",{className:"kui-agent-edited","data-testid":`${T}-agent-edited`,children:[h.jsx(f0,{size:12,strokeWidth:na,"aria-hidden":"true"}),E("agentEdited")]}):((pe=x.editedBy)==null?void 0:pe.by)==="system"?h.jsx("span",{className:"kui-host-edited","data-testid":`${T}-host-edited`,title:x.editedBy.originLabel,children:E("hostEdited")}):null,h.jsx(iT,{}),u,f&&o!=null?h.jsx(sT,{zoom:o,onZoom:I=>{var ye;return(ye=f.current)==null?void 0:ye.zoomTo(I)},onFit:()=>{var I;return(I=f.current)==null?void 0:I.fit()},labels:{out:E("zoomOut"),in:E("zoomIn"),fit:E("fit")}}):null]}):null,M.dialog?h.jsx(ok,{command:M.dialog.command,values:M.dialog.values,title:M.phrase(M.dialog.command.title),labels:{run:E("run"),cancel:E("cancel"),required:E("required"),more:E("moreOptions")},onClose:()=>M.setDialog(null),onRun:I=>{const ye=M.dialog.command.id;M.setDialog(null),M.run(ye,I)}},M.dialog.command.id):null,J?h.jsx(Bk,{catalog:J,personal:G.config.personal,labels:{title:E("customizeTitle"),search:E("customizeSearch"),restore:E("customizeRestore"),cancel:E("cancel"),save:E("customizeSave")},onSave:I=>{$(null),se.current(I)},onClose:()=>$(null)}):null,le?h.jsx(Fk,{x:le.x,y:le.y,label:E("hideElement"),testId:`${T}-hide-element`,onHide:()=>{Z(null),se.current([...G.store.get().personal,le.id])},onClose:ie}):null,h.jsx(oT,{})]})})}function Jk(l,s,u,c=()=>!0){const f=new Map;for(const d of l){const[p,y]=d.menu;if(!p||u.includes(d.id)||!c(d))continue;const g=f.get(p)??{label:p,commands:[],submenus:new Map};y?g.submenus.set(y,[...g.submenus.get(y)??[],d]):g.commands.push(d),f.set(p,g)}const o=d=>s.includes(d)?s.indexOf(d):s.length;return[...f.values()].sort((d,p)=>o(d.label)-o(p.label))}function Pk({label:l,path:s,children:u,uiId:c,testId:f}){const o=c??`menu:${s}`,{phrase:d}=Ne(),p=w.useRef(null),y=w.useRef(null),g=w.useRef(null),[v,b]=w.useState(null),M=w.useRef(!1),z=()=>{var N;const C=(N=p.current)==null?void 0:N.getBoundingClientRect();C&&b({left:C.right-2,top:C.top-4,maxHeight:Math.max(0,window.innerHeight-16)})},x=()=>{var C,N;(C=g.current)!=null&&C.contains(document.activeElement)&&((N=y.current)==null||N.focus()),b(null)},E=w.useCallback(()=>{var ae;const C=(ae=p.current)==null?void 0:ae.getBoundingClientRect(),N=g.current;if(!C||!N)return;const G=Math.max(0,window.innerHeight-16),J=Math.min(N.scrollHeight,G),$=N.offsetWidth,le=C.right-2,Z=le+$<=window.innerWidth-4?le:C.left+2-$>=4?C.left+2-$:le,ie=Math.max(4,Math.min(Z,window.innerWidth-$-4)),se=Math.max(8,Math.min(C.top-4,window.innerHeight-8-J));b(de=>!de||de.left===ie&&de.top===se&&de.maxHeight===G?de:{left:ie,top:se,maxHeight:G})},[]),T=v!=null;return w.useLayoutEffect(()=>{if(!T)return;E();const C=g.current;if(!C||typeof ResizeObserver>"u")return;const N=new ResizeObserver(()=>E());N.observe(C);for(const G of C.children)N.observe(G);return()=>N.disconnect()},[T,E]),w.useLayoutEffect(()=>{var C;!v||!M.current||!g.current||(M.current=!1,(C=g.current.querySelector('[role^="menuitem"]:not(:disabled)'))==null||C.focus())},[v]),h.jsxs("div",{ref:p,className:"kui-submenu",onPointerEnter:z,onPointerLeave:x,children:[h.jsxs("div",{ref:y,className:"kui-menu-item",role:"menuitem","aria-haspopup":"menu","aria-expanded":v!=null,tabIndex:-1,"data-kit-ui-id":o,"data-testid":f,onKeyDown:C=>{C.target!==C.currentTarget||!["ArrowRight","Enter"," "].includes(C.key)||(C.preventDefault(),C.stopPropagation(),M.current=!0,z())},children:[h.jsx("span",{style:{width:15}}),h.jsx("span",{children:d(l)}),h.jsx(ws,{size:13,strokeWidth:na,"aria-hidden":"true",style:{marginLeft:"auto",opacity:.6}})]}),v?h.jsxs("div",{ref:g,className:"kui-popover kui-submenu-popover",role:"menu",style:{left:v.left,top:v.top,maxHeight:v.maxHeight},onKeyDown:C=>{C.key==="ArrowLeft"?(C.preventDefault(),C.stopPropagation(),x()):cg(C,x)},children:[u,h.jsx(Lu,{place:o,as:"menu"})]}):null]})}function Wk({children:l}){const{t:s}=Ne();return h.jsx(Au,{className:"kui-options-strip",panelClassName:"kui-options-bar",labels:{start:s("optionsScrollStart"),end:s("optionsScrollEnd")},testId:"options-scroll",children:l})}const eA=400;function aA({tools:l,shown:s,active:u,onSelect:c,rail:f,pressMs:o}){const{testId:d,t:p}=Ne(),y=ya(),[g,v]=w.useState(null),b=w.useRef(null),M=w.useRef(null),z=w.useRef(!1);w.useEffect(()=>{const T=()=>{z.current=!1};return window.addEventListener("pointerdown",T,!0),()=>window.removeEventListener("pointerdown",T,!0)},[]);const x=()=>{var N,G;const T=(N=b.current)==null?void 0:N.getBoundingClientRect(),C=((G=f.current)==null?void 0:G.getBoundingClientRect().right)??(T==null?void 0:T.right);T&&C!=null&&l.length>1&&v({left:C+4,top:Math.min(T.top,window.innerHeight-l.length*30-16)})};w.useEffect(()=>{if(!g)return;const T=C=>{var N;(!(C.target instanceof Node)||!((N=document.querySelector(".kui-tool-flyout"))!=null&&N.contains(C.target)))&&v(null)};return window.addEventListener("pointerdown",T,!0),()=>window.removeEventListener("pointerdown",T,!0)},[g]);const E=s.shortcut?`${s.label} (${s.shortcut})`:s.label;return h.jsxs("span",{ref:b,className:"kui-tool-slot","data-grouped":l.length>1,onContextMenu:T=>{var C;T.preventDefault(),l.length>1?x():(C=y.offerHide)==null||C.call(y,`tool:${s.id}`,T.clientX,T.clientY)},onPointerDown:T=>{z.current=!1,T.button===0&&(M.current=window.setTimeout(()=>{z.current=l.length>1,x()},o))},onPointerUp:()=>M.current!=null&&window.clearTimeout(M.current),onPointerLeave:()=>{z.current=!1,M.current!=null&&window.clearTimeout(M.current)},children:[h.jsx(Ge,{icon:s.icon,label:E,pressed:l.some(T=>T.id===u),disabled:y.state(`tool:${s.id}`).disabled,onClick:()=>{z.current?z.current=!1:c(s.id)},"data-testid":`${d}-tool-${s.id}`,"data-kit-ui-id":`tool:${s.id}`}),g?h.jsxs("div",{className:"kui-popover kui-tool-flyout",role:"menu",style:{left:g.left,top:g.top},children:[l.map(T=>h.jsxs("button",{type:"button",role:"menuitemradio","aria-checked":T.id===u,className:"kui-menu-item",disabled:y.state(`tool:${T.id}`).disabled,onClick:()=>{v(null),c(T.id)},"data-testid":`${d}-tool-${T.id}`,"data-kit-ui-id":`tool:${T.id}`,children:[h.jsx(T.icon,{size:15,strokeWidth:na,"aria-hidden":"true"}),h.jsx("span",{children:T.label}),T.shortcut?h.jsx("kbd",{children:T.shortcut}):null]},T.id)),y.hide?h.jsxs("button",{type:"button",role:"menuitem",className:"kui-menu-item","data-kit-ui-id":`tool:${s.id}`,"data-testid":`${d}-tool-hide`,onClick:()=>{var T;v(null),(T=y.hide)==null||T.call(y,`tool:${s.id}`)},children:[h.jsx("span",{style:{width:15}}),h.jsx("span",{children:p("hideElement")})]}):null]}):null]})}const tA=30,nA=11,lA=16;function iA(l,s,u){return lA+l*tA+Math.max(0,s-1)*nA>u}function sA(l,s){const u=[];for(let c=0;c<l.length;c+=s)u.push(l.slice(c,c+s));return u}function rA({tools:l,active:s,onSelect:u,columns:c=1,onColumns:f,columnsUiId:o,slotMemory:d=!0,flyoutPressMs:p=eA}){var ae,de;const{testId:y,t:g}=Ne(),[v,b]=w.useState(new Map),M=(ae=l.find(q=>q.id===s))==null?void 0:ae.group;w.useEffect(()=>{M!=null&&b(q=>q.get(M)===s?q:new Map(q).set(M,s))},[s,M]);const[z,x]=w.useState(!1),E=w.useRef(null),T=ya(),C=l.filter(q=>!T.state(`tool:${q.id}`).hidden),N=T.state(`tool:${s}`).denied?(de=C.find(q=>!T.state(`tool:${q.id}`).denied))==null?void 0:de.id:void 0,G=w.useRef(u);G.current=u,w.useLayoutEffect(()=>{N&&G.current(N)},[N]);const J=[];for(const q of C){const ue=J.at(-1);ue&&q.group!=null&&ue[0].group===q.group?ue.push(q):J.push([q])}const $=[];for(const q of J){const ue=$.at(-1);ue&&ue[0][0].section===q[0].section?ue.push(q):$.push([q])}w.useEffect(()=>{if(c!=="auto"||typeof ResizeObserver>"u")return;const q=E.current,ue=q==null?void 0:q.parentElement;if(!q||!ue)return;const we=()=>x(iA(J.length,$.length,ue.getBoundingClientRect().bottom-q.getBoundingClientRect().top)),D=new ResizeObserver(we);return D.observe(ue),()=>D.disconnect()},[c,J.length,$.length]);const le=c===2||c==="auto"&&z?2:1,Z=o?T.state(o):{hidden:!1,disabled:!1},ie=q=>{T.state(`tool:${q}`).denied||u(q)},se=q=>{const ue=L=>!T.state(`tool:${L.id}`).denied,we=q[0].group==null||!d?void 0:v.get(q[0].group),D=q.find(L=>L.id===s)??q.find(L=>L.id===we&&ue(L))??q.find(ue)??q[0];return h.jsx(aA,{tools:q,shown:D,active:s,onSelect:ie,rail:E,pressMs:p},q[0].id)};return h.jsxs("div",{className:"kui-tool-rail",role:"toolbar","aria-orientation":"vertical","data-testid":`${y}-tool-rail`,"data-columns":le,ref:E,children:[f&&c!=="auto"&&!Z.hidden?h.jsx("button",{type:"button",className:"kui-tool-rail-columns","aria-label":g(c===2?"railOneColumn":"railTwoColumns"),title:g(c===2?"railOneColumn":"railTwoColumns"),disabled:Z.disabled,onClick:()=>f(c===2?1:2),"data-testid":`${y}-tool-rail-columns`,"data-kit-ui-id":o,children:c===2?h.jsx(Px,{size:12,strokeWidth:na,"aria-hidden":"true"}):h.jsx(Wx,{size:12,strokeWidth:na,"aria-hidden":"true"})}):null,$.map((q,ue)=>h.jsxs(w.Fragment,{children:[ue>0?h.jsx("div",{className:"kui-tool-rail-divider","aria-hidden":"true"}):null,le===2?sA(q,2).map(we=>h.jsx("div",{className:"kui-tool-rail-row",children:we.map(se)},we[0][0].id)):q.map(se)]},q[0][0].id))]})}function uA({hidden:l=[]}){const s=mi(),{phrase:u,host:c}=Ne();if(!s||c.readOnly)return null;const f=s.tools.filter(o=>!l.includes(o.id)).map(o=>({id:o.id,label:u(o.label),icon:M0(o.icon,o.id),shortcut:o.shortcut,group:o.group}));return h.jsx(rA,{tools:f,active:s.active,onSelect:s.select})}function _n({id:l,title:s,children:u,defaultOpen:c=!0,actions:f,testId:o}){const[d,p]=w.useState(c),y=ya();l&&y.declared;const g=l?y.state(l):null;return g!=null&&g.hidden?null:h.jsxs("section",{className:"kui-panel-section","data-open":d,"data-testid":o,"data-kit-ui-id":l,children:[h.jsxs("div",{className:"kui-panel-section-header",children:[h.jsxs("button",{type:"button",className:"kui-panel-section-toggle","aria-expanded":d,onClick:()=>p(v=>!v),children:[h.jsx(ws,{size:13,strokeWidth:na,"aria-hidden":"true",className:"kui-panel-section-chevron"}),s]}),h.jsx("fieldset",{className:"kui-element",disabled:(g==null?void 0:g.disabled)??!1,children:f})]}),d?h.jsx("div",{className:"kui-panel-section-body",children:h.jsx("fieldset",{className:"kui-element",disabled:(g==null?void 0:g.disabled)??!1,children:u})}):null]})}function X1(l){const s=l instanceof Uint8Array?l:new Uint8Array(l);let u="";for(let c=0;c<s.length;c+=32768)u+=String.fromCharCode(...s.subarray(c,c+32768));return btoa(u)}const cA=["png","jpg","jpeg","gif","webp","svg","bmp"];function _g(){const l=Ne(),{host:s,t:u}=l,c=s.init.capabilities.includes("pick-file"),f=w.useCallback(async(o,d)=>{try{const p=await s.pick(o,d);if(!p)return null;const{bytes:y}=await s.files.read(p);return{path:p,name:p.split("/").pop()??p,bytes:y}}catch(p){return $1(l,u("commandFailed"),p),null}},[l,s,u]);return{can:c,pick:f}}function Ln(l,s={},u=null){const{query:c,session:f}=Ne(),[o,d]=w.useState(null),p=JSON.stringify(s);return w.useEffect(()=>{if(!f.doc)return;let y=!1;return c(l,JSON.parse(p)).then(g=>{y||d(g)}),()=>{y=!0}},[u,l,p,c,f.change.revision,f.doc]),o}function oA(l,s){return l===s||l==="*"||s==="*"}function fA(l,s){return l.find(u=>!u.holder.self&&oA(u.scope,s))??null}const K1=[],$m=new WeakMap;function Xm(l){return Array.isArray(l)?l.filter(s=>{var u;return!!s&&typeof s.scope=="string"&&typeof((u=s.holder)==null?void 0:u.name)=="string"}):K1}function dA(l){const s=l.init.capabilities.includes("lease");let u=K1;const c=new Set,f=o=>{u=o.length?o:K1;for(const d of[...c])d()};if(s){let o=!1;l.peer.on("lease/changed",d=>{o=!0,f(Xm(d==null?void 0:d.leases))}),l.peer.request("host/leases",{}).then(d=>{o||f(Xm(d==null?void 0:d.leases))},()=>{})}return{available:s,list:()=>u,subscribe:o=>(c.add(o),()=>c.delete(o)),heldByOther:o=>fA(u,o),acquire:async(o,d)=>{var p;if(l.readOnly)return{granted:!1,reason:"read-only",holder:null};if(!s)return{granted:!0,lease:null};try{const{lease:y}=await l.peer.request("host/leaseAcquire",d===void 0?{scope:o}:{scope:o,ttl:d});return{granted:!0,lease:y??null}}catch(y){const g=y instanceof ta?y.data:void 0;return(g==null?void 0:g.reason)===P1?{granted:!1,reason:"held",holder:((p=g.lease)==null?void 0:p.holder)??null}:(g==null?void 0:g.reason)==="read-only"?{granted:!1,reason:"read-only",holder:null}:{granted:!0,lease:null}}},release:async o=>{s&&await l.peer.request("host/leaseRelease",{scope:o}).catch(()=>{})}}}function Km(l){let s=$m.get(l);return s||$m.set(l,s=dA(l)),s}function au(l,s){const u=s==null?`\`${l}\``:`step ${s} (\`${l}\`)`;return new ta(-32e3,`${u} is not allowed: the document is read-only`,s==null?{reason:Ht,command:l}:{reason:Ht,command:l,step:s})}function Im(l){return new ta(-32e3,l.message,l)}function I1(l){return l instanceof Error?l.message:String(l)}function hA(l){const{origin:s,originLabel:u,draft:c}=l;if(s===void 0){if(u!==void 0)throw new ta(-32602,'`originLabel` names a host feature: it needs `origin: "system"`');return{by:"agent"}}if(s!=="system")throw new ta(-32602,`\`origin\` is "system" or absent, not ${JSON.stringify(s)}`);if(c===!0)throw new ta(-32602,"a host's change (`origin: \"system\"`) is made on the document, not on the agent's draft");if(u!==void 0&&(typeof u!="string"||!eb.test(u)))throw new ta(-32602,`\`originLabel\` is 1 to 64 letters, digits, \`.\`, \`_\` or \`-\`, not ${JSON.stringify(u)}`);return{by:"system",originLabel:u??ab}}function mA(l,s,u){const c=`step ${u} (\`${s}\`) failed`;return l instanceof g0?new ta(-32e3,`${c}: ${l.message}`,{reason:xu,command:s,step:u,errors:l.errors}):l instanceof zg?new ta(-32e3,`${c}: ${l.message}`,{reason:l.reason,command:s,step:u}):l instanceof ta?new ta(l.code,`${c}: ${l.message}`,l.data):new Error(`${c}: ${I1(l)}`)}const vA=new Set(["edit.undo","edit.redo"]),Zm={scope:"agent"};function pA(l,s){return new ta(-32e3,`step ${s} (\`${l}\`) cannot run in a call context: this kit's engine keeps no editor state of the agent's own, so its \`on\`, \`part\` and \`time\` cannot be set without moving the person's`,{reason:V1,command:l,step:s})}function yA(l,s){const u=s.toLowerCase().split(/\s+/).filter(Boolean);return l.filter(c=>{const f=`${c.id} ${c.title} ${c.description??""} ${c.params??""}`.toLowerCase();return u.every(o=>f.includes(o))}).map(c=>({id:c.id,title:c.title,description:c.description,enabled:c.enabled,mutates:c.mutates,schema:c.schema??null}))}function gA(l,s,u,c){const f=(c==null?void 0:c.name)||"another session";return new ta(-32e3,`step ${s} (\`${l}\`) is not allowed: ${f} holds the lease on \`${u}\``,{reason:P1,command:l,step:s,scope:u,...c?{holder:c}:{}})}async function MA(l,s,u,c,f,o){if(!s){const p=u?l.list().find(y=>!y.holder.self&&y.scope==="*"):void 0;if(p)throw o("*",p.holder);return f()}const d=await l.acquire(s,c);if(!d.granted){const p=d;if(p.reason==="read-only")return f();throw o(s,p.holder)}try{return await f()}finally{d.lease&&await l.release(s)}}function bA(l,s,u,c={}){var pe,I,ye;const f=l.init.document.path,o=l.readOnly===!0,d=o&&((pe=l.init.document.comments)==null?void 0:pe.canComment)===!0,p=s.commentCommands,y=w.useMemo(()=>YT(p,d),[d,p]),g=WT(l.files,s,f,!0,u,{readOnly:o,canComment:d,replicaMergesFile:c.replicaMergesFile,followFile:c.followFile}),{doc:v,failure:b}=g,M=(v==null?void 0:v.info.revision)??null,z=(v==null?void 0:v.info.dirty)??!1,x=w.useRef(g);x.current=g;const E=w.useRef({doc:null,map:null,commands:null,loading:null}),T=w.useCallback(te=>{const oe=E.current;if(oe.doc===te&&oe.loading)return oe.loading;const k=te.commands().then(j=>{const U=new Map(j.map(Q=>[Q.id,Q.menu]));return E.current.loading===k&&(E.current={doc:te,map:U,commands:new Map(j.map(Q=>[Q.id,Q])),loading:k}),U});return k.catch(()=>{E.current.loading===k&&(E.current={doc:null,map:null,commands:null,loading:null})}),E.current={doc:te,map:null,commands:null,loading:k},k},[]);w.useEffect(()=>{v&&T(v).catch(()=>{})},[v,T]);const C=w.useCallback(te=>{var k;const oe=(k=E.current.commands)==null?void 0:k.get(te);return yu(oe??{id:te},y)},[y]),N=w.useCallback(async(te,oe={},k=null,j={})=>{const U=x.current.doc;if(!U)return null;const Q=E.current,ve=Q.doc===U&&Q.map?Q.map:await T(U);if(Oa(l.ui.get(),`command:${te}`,ve.get(te)??[]).denied)throw Wr(te);if(o&&C(te))throw au(te);try{return await g.run(te,oe,k,j)}catch(Se){throw Sg(Se)?au(te):Se}},[C,l,T,o,g.run]),G=c.agentSkipsUnchangedPaint===!0,J=w.useRef(c);J.current=c;const $=w.useMemo(()=>Cg(Rg,l.init.locale),[l]),le=c.agentLeaseScope!=null;w.useEffect(()=>{le&&Km(l)},[l,le]);const Z=w.useRef(Promise.resolve()),ie=w.useRef(null),se=w.useRef(null),[ae,de]=w.useState(null),q=w.useCallback((te,oe)=>{se.current={edit:te,revision:oe},de(te)},[]),ue=w.useRef(!1),we=w.useRef({doc:null,version:null}),D=w.useRef(null);D.current??(D.current=new ak({open:()=>x.current.draft.open(),merge:(te,oe,k,j)=>x.current.draft.merge(te,oe,k,j),compare:(te,oe)=>x.current.draft.compare(te,oe),preview:async te=>{const oe=x.current.doc;return oe?G1(oe,te).catch(()=>null):null},changed:te=>l.peer.notify("draft/changed",te)})),w.useEffect(()=>{const te=D.current;return te.attach(),()=>te.dispose()},[]),w.useEffect(()=>{ue.current||(v?(ue.current=!0,l.opened([...v.info.model?["model","draft","draft-model","check"]:["check"],...v.info.context?["context"]:[],...v.info.changes?["changes"]:[],...v.info.premises?["premises"]:[]])):b&&(ue.current=!0,l.failed(new Error(b))))},[v,b,l]),w.useEffect(()=>{var oe;if(!v)return;const te=ie.current??(((oe=se.current)==null?void 0:oe.revision)===v.info.revision?se.current.edit:{by:"person"});te.by==="person"&&se.current&&(se.current=null,de(null)),l.changed({dirty:v.info.dirty,revision:v.info.revision,title:l.init.document.name,...te})},[v,l,M,z]);const L=((I=v==null?void 0:v.info.schema)==null?void 0:I.reads)??null,P=((ye=v==null?void 0:v.info.schema)==null?void 0:ye.newestAuthor)??null,re=w.useRef(null);return w.useEffect(()=>{if(L===null||P===null||P<=L)return;const te=`${L}:${P}`;re.current!==te&&(re.current=te,l.peer.notify("document/schema",{reads:L,newestAuthor:P}))},[l,P,L]),w.useEffect(()=>{if(!l.replica||!v)return;const te=v.info.replica??null,oe=te?te.join(","):null,k=we.current;we.current={doc:v,version:oe},!(k.doc!==v||!te||oe===k.version)&&l.peer.notify("replica/changed",{version:te.slice().buffer})},[v,l,M]),w.useEffect(()=>{const{peer:te}=l;te.handle("document/state",()=>{const ne=x.current.doc;return{dirty:(ne==null?void 0:ne.info.dirty)??!1,revision:(ne==null?void 0:ne.info.revision)??0,title:l.init.document.name}}),te.handle("document/save",async()=>{var ne;if(o)throw new ta(-32e3,"the document is read-only",{reason:Ht});return await x.current.save(),{saved:!(((ne=x.current.doc)==null?void 0:ne.info.dirty)??!0),version:null}});const oe=()=>{const ne=x.current.doc;if(!ne)throw new Error("the document is still opening");return ne},k=D.current,j=ne=>{if(o)throw new ta(-32e3,"a draft is not allowed: the document is read-only",{reason:Ht});return k.engine(ne)};te.handle("ai/inspect",async ne=>{const he=(ne==null?void 0:ne.draft)===!0,Ee=he?await j(!1):oe(),{width:xe,height:Oe,dirty:je,canUndo:H,canRedo:F,inspected:ce}=Ee.info,me=`${xe} × ${Oe}${he?", draft":je?", unsaved":""}`,ze=ne.context?await Ee.inspectAt(ne.context,ne.part):{details:ce};return Ee.agentReply({path:f,kit:s.kitId,revision:Ee.info.revision,summary:me,dirty:he?!1:je,canUndo:H,canRedo:F,...ze,...he?{draft:k.info()}:{}})}),te.handle("document/check",async ne=>{const he=(ne==null?void 0:ne.draft)===!0?await j(!1):oe();return he.agentReply({diagnostics:await he.check()})}),te.handle("ai/commands",async({query:ne})=>{const he=_T(l.ui.get(),await oe().commands());return yA(o?he.map(Ee=>yu(Ee,y)?{...Ee,enabled:!1}:Ee):he,ne)}),te.handle("ai/run",async ne=>{const{steps:he,save:Ee,draft:xe}=ne,Oe=hA(ne),je=oe(),H=await T(je),F=HT(l.ui.get(),he,ze=>H.get(ze)??[]);if(F>=0)throw Wr(he[F].command,F);const ce=o?he.findIndex(ze=>C(ze.command)):-1;if(ce>=0)throw au(he[ce].command,ce);if(xe===!0)return Le(await j(!0),he);const me=je.info.context===!0?-1:he.findIndex(ze=>ze.context!=null);if(me>=0)throw pA(he[me].command,me);return ve(()=>U(je,he,Ee,Oe))});const U=async(ne,he,Ee,xe)=>{var ze,ke,We,ea;const Oe=[],je=xe.by==="system"?{kind:"system",principal:"kdm",label:xe.originLabel}:{kind:"agent",principal:((ze=l.init.document.comments)==null?void 0:ze.me)??"agent",label:"ai/run"},H={last:null,meanwhile:!1},F=ne.info.context===!0?{state:null}:null,ce=Ie=>({...G?{skipUnchangedPaint:!0}:{},origin:je,...F?{agent:{state:F,set:Ie}}:{}});ie.current=xe;try{for(const[Ie,Je]of he.entries()){let Ra=ne.info.revision,qt;try{const qa=()=>(Ra=ne.info.revision,H.last!==null&&Ra!==H.last&&(H.meanwhile=!0),N(Je.command,Je.params??{},null,ce(Je.context??null)));qt=await Se(ne,Je.command,Je.params??{},Ie,qa,xe)}catch(qa){if(qa instanceof ta&&((ke=qa.data)==null?void 0:ke.reason)===P1)throw qa;const vl=qa instanceof ta&&((We=qa.data)==null?void 0:We.reason)==="not-allowed"?Wr(Je.command,Ie):qa instanceof ta&&((ea=qa.data)==null?void 0:ea.reason)===Ht?au(Je.command,Ie):mA(qa,Je.command,Ie);throw xe.by==="system"?vl:await Q(ne,Oe,vl,Je.command,Ie,H,ce(null),xe)}let it=qt;try{it=qt==null?null:JSON.parse(qt)}catch{}if(H.last=ne.info.revision,Oe.push({command:Je.command,changed:ne.info.revision!==Ra,result:it}),it!==null&&typeof it=="object"&&"closed"in it&&it.closed===!0)return{completed:Oe,closed:!0,saved:!1,notRun:he.length-Oe.length}}}finally{ie.current=null}Oe.some(Ie=>Ie.changed)&&q(xe,ne.info.revision);const me=!o&&!Oa(l.ui.get(),"action:save").denied;return Ee&&me&&ne.info.dirty&&await x.current.save(),ne.agentReply({completed:Oe,saved:Ee&&me&&!ne.info.dirty})},Q=async(ne,he,Ee,xe,Oe,je,H,F)=>{const ce=Ee instanceof ta&&Ee.data&&typeof Ee.data=="object"?Ee.data:{},me=Ee instanceof ta?Ee.code:-32e3,ze=(Je,Ra,qt)=>{const it={...ce,command:xe,step:Oe,completed:Ra,...qt?{rolledBack:qt}:{}};return je.meanwhile&&(it.editedMeanwhile=!0),new ta(me,`${Ee.message}${Je}`,it)},ke=he.filter(Je=>Je.changed).length,We=Je=>ze(` The ${he.length} step(s) before it could not be rolled back (${Je}): they stay in the document; undo them (\`edit.undo\`) or keep them.`,he,null);if(je.last!==null&&ne.info.revision!==je.last&&(je.meanwhile=!0),ke===0)return ze(he.length?` The ${he.length} step(s) before it were rolled back: the document is as it was before the run.`:"",[],he);if(he.some(Je=>vA.has(Je.command)))return We("the steps undid or redid edits themselves");if(je.meanwhile&&ne.info.origins!==!0)return We("someone else edited the document while the run was under way, and this kit's engine cannot take back the agent's steps alone: it does not run commands as an origin");let ea=0,Ie="";for(;ea<ke;){const Je=ne.info.revision;je.last!==null&&Je!==je.last&&(je.meanwhile=!0);try{await Se(ne,"edit.undo",Zm,Oe,()=>N("edit.undo",Zm,null,H),F)}catch(Ra){Ie=I1(Ra);break}if(ne.info.revision===Je){Ie="the kit had nothing more to undo";break}ea+=1,je.last=ne.info.revision}if(ea===0)return We(Ie);if(ea<ke){let Je=ke-ea,Ra=0;for(;Je>0;)he[Ra++].changed&&(Je-=1);return ze(` Only ${ea} of the ${ke} step(s) that changed the document could be rolled back (${Ie}): the first ${Ra} step(s) stay in the document.`,he.slice(0,Ra),he.slice(Ra))}return je.meanwhile?ze(` The ${he.length} step(s) before it were rolled back in the agent's undo scope, but someone else edited the document while the run was under way: their edits stay, and where they changed what those steps made or changed, their change was kept (an object a step created went, with what they did to it). Inspect the document before going on.`,[],he):ze(` The ${he.length} step(s) before it were rolled back: the document is as it was before the run.`,[],he)},ve=ne=>{const he=Z.current.then(ne,ne);return Z.current=he.then(()=>{},()=>{}),he},Se=async(ne,he,Ee,xe,Oe,je)=>{var ze,ke;const H=J.current.agentLeaseScope,F=H?Km(l):null;if(!H||!(F!=null&&F.available))return Oe();let ce="";try{ce=await H(he,Ee,ne)||""}catch{ce=""}const me=((ke=(ze=E.current.commands)==null?void 0:ze.get(he))==null?void 0:ke.mutates)??!0;return MA(F,ce,me,J.current.agentLeaseTtl,Oe,(We,ea)=>(je.by==="agent"&&l.notify({level:"warning",title:$("agentLeaseHeld",{name:(ea==null?void 0:ea.name)||$("someone")})}),gA(he,xe,We,ea)))};te.handle("ai/preview",async({maxSize:ne,draft:he})=>({png:await G1(he===!0?await j(!1):oe(),ne)}));const Le=async(ne,he)=>{const Ee=[];let xe=!1;try{for(const[Oe,je]of he.entries()){const H=ne.info.revision;let F;try{F=await ne.execute(je.command,je.params??{})}catch(me){throw me instanceof g0?new ta(-32e3,`step ${Oe} (\`${je.command}\`) failed on the draft: ${me.message}`,{reason:xu,command:je.command,step:Oe,errors:me.errors}):new Error(`step ${Oe} (\`${je.command}\`) failed on the draft: ${I1(me)}`)}let ce=F;try{ce=F==null||F===""?null:JSON.parse(F)}catch{}if(Ee.push({command:je.command,changed:ne.info.revision!==H,result:ce}),ce!==null&&typeof ce=="object"&&"closed"in ce&&ce.closed===!0)return xe=!0,{completed:Ee,closed:!0,saved:!1,notRun:he.length-Ee.length}}}finally{!xe&&Ee.some(Oe=>Oe.changed)&&k.edited()}return{completed:Ee,saved:!1}};te.handle("draft/state",()=>k.info()),te.handle("draft/ready",()=>k.ready()),te.handle("draft/reopen",()=>k.reopen()),te.handle("draft/compare",ne=>k.compare(Math.max(1,Number(ne==null?void 0:ne.maxSize)||1024),(ne==null?void 0:ne.schema)??null)),te.handle("draft/merge",async({origin:ne,schema:he=null})=>{var xe,Oe;if(o)throw new ta(-32e3,"the document is read-only",{reason:Ht});const Ee={kind:"agent",principal:String((ne==null?void 0:ne.principal)??""),...ne!=null&&ne.label?{label:String(ne.label)}:{}};ie.current={by:"agent"};try{const je=await k.merge(Ee,he),H=x.current.doc;return H&&q({by:"agent"},H.info.revision),je.merged&&((Oe=(xe=J.current).draftMerged)==null||Oe.call(xe,{summary:je.summary})),je}catch(je){throw je instanceof os?Im(je.data):je}finally{ie.current=null}}),te.handle("draft/discard",()=>k.discard());const ge=async ne=>{if(!oe().info.model)throw new ta(-32601,"the kit's engine does not answer the object model");try{return await ne()}catch(he){throw he instanceof os?Im(he.data):he}};te.handle("model/describe",ne=>ge(()=>x.current.model.describe((ne==null?void 0:ne.schema)??null)));const Te=ne=>{if(oe().info.changes!==!0)throw new ta(-32601,"the kit's engine keeps no replica, so it cannot say what changed");return ne()};te.handle("ai/version",()=>Te(async()=>({version:await x.current.model.version()}))),te.handle("ai/changes",ne=>Te(()=>x.current.model.changes(String((ne==null?void 0:ne.since)??""),(ne==null?void 0:ne.schema)??null))),te.handle("ai/premise",({method:ne,params:he})=>oe().premiseRead(ne,he)),te.handle("model/batch",ne=>ge(async()=>{const{schema:he=null,draft:Ee,...xe}=ne??{},Oe=Array.isArray(xe.ops)?xe.ops:[];if(o&&Oe.length)throw new os({code:Ht,index:null,message:"the document is read-only"});const je=await T(oe());if(Oe.forEach((F,ce)=>{if((F==null?void 0:F.op)==="command"&&typeof F.id=="string"&&Oa(l.ui.get(),`command:${F.id}`,je.get(F.id)??[]).denied)throw new os({code:"command-failed",index:ce,message:Wr(F.id).message})}),Ee!==!0)return x.current.model.batch(xe,he);const H=await(await j(Oe.length>0)).modelBatch(xe,he);return Oe.length&&k.edited(),H}));const Ha=te.on("document/fileChanged",()=>void x.current.checkFile()),Vt=te.on("document/held",ne=>{typeof(ne==null?void 0:ne.version)=="string"&&x.current.holdFile(ne.version)});return l.replica&&(te.handle("replica/version",async()=>({version:await x.current.replica.version()})),te.handle("replica/export",({since:ne})=>x.current.replica.exportChanges(ne)),te.handle("replica/import",async({changes:ne,blobs:he})=>({damage:await x.current.replica.importChanges(ne,he)})),te.handle("replica/info",async()=>({docId:await x.current.replica.docId()}))),()=>{Ha(),Vt()}},[y,q,C,l,s.kitId,T,f,o,N,G,$]),{...g,run:N,editedBy:ae,comments:y}}const wA=4e3;function SA({tool:l,onExit:s}){const u=Ne(),c=mi(),f=ya(),{undo:o}=S0(),{host:d,t:p,testId:y,phrase:g}=u,v=c==null?void 0:c.tools.find(T=>T.id===c.active),b=l??(v?{label:g(v.label),icon:M0(v.icon,v.id)}:null),M=f.state("action:agent"),z=b==null?void 0:b.icon,[x,E]=w.useState(!0);return w.useEffect(()=>{const T=setTimeout(()=>E(!1),wA);return()=>clearTimeout(T)},[]),h.jsxs("div",{className:"kui-focus-bar",role:"toolbar","aria-label":p("focusBar"),"data-fresh":x||void 0,"data-testid":`${y}-focus-bar`,children:[h.jsxs(ua,{variant:"ghost",className:"kui-focus-exit",title:`${p("exitFocus")} (Esc)`,onClick:s,"data-testid":`${y}-focus-exit`,"data-kit-ui-id":"action:mode",children:[h.jsx(XC,{size:16,strokeWidth:na,"aria-hidden":"true"}),p("exitFocus"),h.jsx("kbd",{children:"Esc"})]}),o.hidden?null:h.jsx(Ge,{icon:m0,label:p("undo"),disabled:o.disabled,onClick:()=>void u.run("edit.undo",{}),"data-testid":`${y}-focus-undo`,"data-kit-ui-id":"action:undo"}),d.init.capabilities.includes("agent")&&!M.hidden?h.jsx(Ge,{icon:f0,label:p("askAgent"),disabled:M.disabled,onClick:()=>void d.openAgent(),"data-testid":`${y}-focus-ask`,"data-kit-ui-id":"action:agent"}):null,b&&z?h.jsxs("span",{className:"kui-focus-tool","data-testid":`${y}-focus-tool`,children:[h.jsx(z,{size:16,strokeWidth:na,"aria-hidden":"true"}),b.label]}):null]})}const zA="---";function xA(l){var u,c;const s=[];for(const f of l)f.kind==="separator"&&(s.length===0||((u=s.at(-1))==null?void 0:u.kind)==="separator")||s.push(f);return((c=s.at(-1))==null?void 0:c.kind)==="separator"&&s.pop(),s}function Ug(l,s,u,c){const f=[],o=new Set;for(const d of l){if(d.path.length===s){d.command===zA?f.push({kind:"separator"}):u(d)&&f.push({kind:"row",row:d});continue}const p=d.path[s];if(o.has(p))continue;o.add(p);const y=d.path.slice(0,s+1).join("/"),g=Ug(l.filter(v=>v.path.length>s&&v.path[s]===p),s+1,u,c);(g.length||c(y))&&f.push({kind:"submenu",label:p,path:y,children:g})}return xA(f)}function CA(l,s,u=()=>!1){const c=[];for(const f of l){const o=f.path[0];o&&!c.includes(o)&&c.push(o)}return c.map(f=>({label:f,children:Ug(l.filter(o=>o.path[0]===f),1,s,u)})).filter(f=>f.children.length>0||u(f.label))}function EA({row:l,checked:s,onKitCommand:u}){const{phrase:c,testId:f}=Ne(),o=ya(),d=Ou(l.command);o.declared;const p=o.state(d,l.path);return h.jsx(Bt,{label:c(l.label),shortcut:l.shortcut,disabled:p.disabled,checked:s,onSelect:()=>!p.denied&&(u==null?void 0:u(l.command)),testId:`${f}-${d.replace(":","-")}`,uiId:d})}function Bg({nodes:l,checked:s,onKitCommand:u,onCommand:c}){const{phrase:f}=Ne();return h.jsx(h.Fragment,{children:l.map((o,d)=>{if(o.kind==="separator")return h.jsx(og,{},`---${d}`);if(o.kind==="submenu")return h.jsx(Pk,{label:o.label,path:o.path,children:h.jsx(Bg,{nodes:o.children,checked:s,onKitCommand:u,onCommand:c})},`menu:${o.path}`);const{row:p}=o,y=`${p.command}@${d}`;return p.command.startsWith(hl)?h.jsx(EA,{row:p,checked:s==null?void 0:s(p.command),onKitCommand:u},y):h.jsx(Xk,{command:p.command,path:p.path,label:f(p.label),shortcut:p.shortcut??void 0,checked:s==null?void 0:s(p.command),onRun:c},y)})})}function TA({tree:l,nodes:s}){var u,c;return h.jsxs(h.Fragment,{children:[(u=l.before)==null?void 0:u.map(f=>h.jsx(Bt,{icon:f.icon,label:f.label,onSelect:f.onSelect,testId:f.testId},f.label)),(c=l.before)!=null&&c.length&&s.length?h.jsx(og,{}):null,h.jsx(Bg,{nodes:s,checked:l.checked,onKitCommand:l.onKitCommand,onCommand:l.onCommand})]})}function kA(l){const{byId:s}=Ne(),{config:u,sessionHidden:c}=ya(),f=w.useRef(new WeakMap);return w.useMemo(()=>{var p;const o=new Map,d=y=>Mg(u,`menu:${y}`).length>0&&!Oa(u,`menu:${y}`).hidden;for(const y of l){if(!y.menu)continue;const{rows:g,hidden:v}=y.menu,b=f.current.get(g);if(b&&b.hidden===v&&b.config===u&&b.byId===s&&b.sessionHidden===c){o.set(y.id,b.nodes);continue}const M=((p=CA(g,z=>{var E;if(v!=null&&v(z)||!z.command.startsWith(hl)&&c(z.command))return!1;const x=Ou(z.command);return!Oa(u,x,z.path).hidden&&!Oa(u,x,((E=s.get(z.command))==null?void 0:E.menu)??[]).hidden},d).find(z=>z.label===y.id))==null?void 0:p.children)??[];f.current.set(g,{hidden:v,config:u,byId:s,sessionHidden:c,nodes:M}),o.set(y.id,M)}return o},[s,u,c,l])}const fs=l=>l.flatMap(s=>s.kind==="row"?[s.row]:s.kind==="submenu"?fs(s.children):[]),AA=5;function Fm({row:l,tree:s,primary:u}){var M,z;const c=Ne(),f=ya(),{byId:o,phrase:d,testId:p}=c,y=d(l.label);if(l.command.startsWith(hl)){const x=Ou(l.command),E=f.state(x,l.path),T=bu({id:l.command.slice(hl.length),title:l.label});return h.jsx(St,{icon:T,lineLabel:T===Mu,primary:u,label:y,pressed:(M=s.checked)==null?void 0:M.call(s,l.command),disabled:E.disabled,onClick:()=>{var C;return!E.denied&&((C=s.onKitCommand)==null?void 0:C.call(s,l.command))},"data-testid":`${p}-${x.replace(":","-")}`,"data-kit-ui-id":x})}const g=o.get(l.command),v=f.state(`command:${l.command}`,l.path),b=bu(g??{id:l.command,title:l.label});return h.jsx(St,{icon:b,lineLabel:b===Mu,primary:u,label:y,pressed:(z=s.checked)==null?void 0:z.call(s,l.command),disabled:!c.enabled(l.command)||v.disabled,onClick:()=>{s.onCommand&&!(g&&Nu(g))?s.onCommand(l.command):c.run(l.command)},"data-testid":`${p}-cmd-${l.command}`,"data-kit-ui-id":`command:${l.command}`})}function jA({tab:l,nodes:s}){var z,x;const{byId:u,phrase:c}=Ne(),f=S0(),o=new Set([...f.undo.hidden?[]:["edit.undo"],...f.redo.hidden?[]:["edit.redo"]]),d=E=>E.filter(T=>!o.has(T.command)),p=E=>{const T=E.find(C=>C.command!=="---");return T?bu(u.get(T.command)??{id:T.command.replace(hl,""),title:T.label}):void 0},y=l.menu;if(!y)return null;const g=d(s.flatMap(E=>E.kind==="row"?[E.row]:[])),v=s.flatMap(E=>E.kind==="submenu"&&d(fs(E.children)).length?[E]:[]),b=y.primary?null:new Set([...g,...v.flatMap(E=>d(fs(E.children)))].filter(E=>E.command!=="---").slice(0,AA).map(E=>E.command)),M=E=>{var T;return b?b.has(E.command):(T=y.primary)==null?void 0:T.includes(E.command)};return h.jsxs(h.Fragment,{children:[g.length||(z=y.before)!=null&&z.length?h.jsx(Rn,{id:`menu:${l.id}`,label:l.label,icon:p(g),children:h.jsxs("div",{className:"kui-command-grid",children:[(x=y.before)==null?void 0:x.map(E=>{const T=E.icon??bu({id:E.testId??E.label,title:E.label});return h.jsx(St,{icon:T,lineLabel:!E.icon&&T===Mu,primary:E.primary,label:E.label,onClick:E.onSelect,"data-testid":E.testId},E.label)}),g.map((E,T)=>h.jsx(Fm,{row:E,tree:y,primary:M(E)},`${E.command}@${T}`))]})}):null,v.map(E=>h.jsx(Rn,{id:`menu:${E.path}`,label:c(E.label),icon:p(d(fs(E.children))),children:h.jsx("div",{className:"kui-command-grid",children:d(fs(E.children)).map((T,C)=>h.jsx(Fm,{row:T,tree:y,primary:M(T)},`${T.command}@${C}`))})},E.path))]})}const Qm={menus:YC,line:fE,classic:B4,focus:k4},Jm=()=>ju()?"Cmd+\\":"Ctrl+\\";function NA({display:l,shown:s,areas:u=!0}){const{t:c,testId:f}=Ne(),o=ya().state("action:mode");if(o.hidden||l.allowed.length<2)return null;if(!u){const g=`${c("mode_focus")} (${Jm()})`;return h.jsx(Ge,{icon:k4,label:g,className:"kui-mode-button",disabled:o.disabled,onClick:()=>l.choose("focus"),"data-testid":`${f}-mode-focus`,"data-kit-ui-id":"action:mode"})}const d=Qm[l.chosen],p=s!==l.chosen,y=p?c("modeStepped",{mode:c(`mode_${l.chosen}`),shown:c(`mode_${s}`)}):c("modeButton",{mode:c(`mode_${l.chosen}`)});return h.jsx(xs,{align:"end",trigger:({toggle:g,open:v})=>h.jsx("button",{type:"button",className:"kui-icon-button kui-mode-button","aria-label":y,title:y,"aria-haspopup":"menu","aria-expanded":v,"data-stepped":p||void 0,disabled:o.disabled,onClick:g,"data-testid":`${f}-mode`,"data-kit-ui-id":"action:mode",children:h.jsx(d,{size:16,strokeWidth:na,"aria-hidden":"true"})}),children:l.allowed.map(g=>h.jsx(Bt,{icon:Qm[g],label:c(`mode_${g}`),shortcut:g==="focus"?Jm():null,checked:g===l.chosen,onSelect:()=>l.choose(g),testId:`${f}-mode-${g}`,uiId:"action:mode"},g))})}function fi(l){return l.menu?`menu:${l.id}`:`tab:${l.id}`}const Pm=new WeakMap;function OA(l){let s=Pm.get(l);if(!s){s=new Map;for(const u of l){const c=u.path[0];if(!c)continue;const f=s.get(c)??[];f.push(u),s.set(c,f)}Pm.set(l,s)}return s}function RA(l,{phrase:s=d=>d,view:u=[],before:c={},primary:f={},...o}={}){return[...OA(l)].map(([d,p])=>({id:d,label:s(d),view:u.includes(d),menu:{rows:p,before:c[d],primary:f[d],...o}}))}const Wm=new WeakMap;function LA(l,s,u){let c=Wm.get(l);c||Wm.set(l,c=new Map);const f=JSON.stringify([s,u]);let o=c.get(f);if(!o){o=[];for(const d of Jk(l,s,u)){for(const p of d.commands)o.push({path:[d.label],label:p.title,command:p.id});d.commands.length&&d.submenus.size&&o.push({path:[d.label],label:"---",command:"---"});for(const[p,y]of d.submenus)for(const g of y)o.push({path:[d.label,p],label:g.title,command:g.id})}c.set(f,o)}return o}function DA(l,{order:s,exclude:u=[],...c}){return RA(LA(l,s,u),c)}function HA(l,s=!0){const{modes:u}=w.useSyncExternalStore(l.ui.subscribe,l.ui.get),c=l.kit.id,[f,o]=w.useState(()=>bT(c)),[d,p]=w.useState(()=>u.default==="focus"),y=yg(u),g=s?y:y.filter(x=>x==="menus"||x==="focus"),v=s?ST({stored:f,rules:u,kit:l.display,readOnly:l.readOnly===!0}):"menus",b=w.useCallback(x=>{if(x==="focus"){p(!0);return}wT(c,x),o(x),p(!1)},[c]),M=w.useCallback(()=>p(x=>!x),[]),z=w.useCallback(()=>p(!1),[]);return{chosen:v,focus:d&&g.includes("focus"),allowed:g,choose:b,toggleFocus:M,exitFocus:z}}function _A(l,s,u,c){const[f,o]=w.useState(Number.POSITIVE_INFINITY),[d,p]=w.useState(()=>new Map);w.useLayoutEffect(()=>{const v=l.current;if(!v||typeof ResizeObserver>"u")return;const b=new ResizeObserver(M=>{var x;const z=(x=M[0])==null?void 0:x.contentRect.width;z!=null&&o(z)});return b.observe(v),()=>b.disconnect()},[l]);const y=zT(s,f,{classic:d.get(`classic:${u}`),line:d.get(`line:${u}`)},c),g=w.useCallback((v,b)=>{const M=l.current;if(!b||!M||typeof ResizeObserver>"u")return;const z=M.getBoundingClientRect().width,x=b.scrollWidth-b.clientWidth,E=`${v}:${u}`;p(T=>{const C=T.get(E);if(x>1){const N=Math.ceil(z+x);return C!==void 0&&Math.abs(C-N)<=1?T:new Map(T).set(E,N)}return C===void 0||C<=z?T:new Map(T).set(E,Math.floor(z))})},[l,u]);return{effective:y,measure:g}}const e5="(pointer: coarse)";function UA(){const[l,s]=w.useState(()=>typeof window<"u"&&typeof window.matchMedia=="function"&&window.matchMedia(e5).matches);return w.useEffect(()=>{var f;if(typeof window>"u"||typeof window.matchMedia!="function")return;const u=window.matchMedia(e5),c=()=>s(u.matches);return(f=u.addEventListener)==null||f.call(u,"change",c),()=>{var o;return(o=u.removeEventListener)==null?void 0:o.call(u,"change",c)}},[]),l}const Vg=w.createContext(null),BA=w.createContext(null);function VA(){return w.useContext(Vg)}const qA=32,a5=2;function GA(l,s,u,c){const f=p=>(s.get(p)??0)+a5;if(l.reduce((p,y)=>p+f(y),0)<=u)return null;let o=u-qA-a5;const d=new Set;c!==null&&l.includes(c)&&(d.add(c),o-=f(c));for(const p of l)if(!d.has(p)){if(f(p)>o)break;d.add(p),o-=f(p)}return d}function YA({tabs:l,active:s,onTab:u}){const{t:c}=Ne(),f=w.useRef(null),o=w.useRef(new Map),[d,p]=w.useState(null),y=w.useRef(()=>{});y.current=()=>{const v=f.current;if(!v)return;const b=z=>`${z.id}
50
50
  ${z.label}`;for(const z of v.querySelectorAll(".kui-ribbon-tab")){const x=l.find(E=>E.id===z.dataset.tab);x&&!z.hidden&&o.current.set(b(x),z.offsetWidth)}const M=l.every(z=>o.current.has(b(z)))?GA(l.map(z=>z.id),new Map(l.map(z=>[z.id,o.current.get(b(z))??0])),v.clientWidth,s):null;p(z=>$A(z,M)?z:M)},w.useLayoutEffect(()=>y.current(),[l,s,d]),w.useLayoutEffect(()=>{const v=f.current;if(!v||typeof ResizeObserver>"u")return;const b=new ResizeObserver(()=>y.current());return b.observe(v),()=>b.disconnect()},[]);const g=d===null?[]:l.filter(v=>!d.has(v.id));return h.jsxs("div",{ref:f,className:"kui-frame-tabs",children:[h.jsx("div",{className:"kui-ribbon-tabs",role:"tablist",children:l.map(v=>h.jsx("button",{type:"button",role:"tab",className:"kui-ribbon-tab","aria-selected":v.id===s,hidden:d!==null&&!d.has(v.id),onClick:()=>u(v.id),"data-tab":v.id,"data-testid":`ribbon-tab-${v.id}`,"data-kit-ui-id":fi(v),children:v.label},v.id))}),g.length>0?h.jsx(xs,{align:"end",trigger:({toggle:v,open:b})=>h.jsx("button",{type:"button",className:"kui-frame-tabs-more","aria-label":c("moreTabs"),title:c("moreTabs"),"aria-haspopup":"menu","aria-expanded":b,onClick:v,"data-testid":"ribbon-tabs-more",children:h.jsx(ci,{size:14,strokeWidth:na,"aria-hidden":"true"})}),children:g.map(v=>h.jsx(Bt,{label:v.label,onSelect:()=>u(v.id),testId:`ribbon-tabs-more-${v.id}`,uiId:fi(v)},v.id))}):null]})}function $A(l,s){return l===null||s===null?l===s:l.size===s.size&&[...l].every(u=>s.has(u))}function XA({tab:l}){const[s,u]=w.useState(!1),c=w.useRef(null),f=ya(),{t:o}=Ne(),d=f.state(fi(l));return h.jsxs("span",{ref:c,style:{display:"inline-flex"},children:[h.jsx("button",{type:"button",className:"kui-menu-bar-item","aria-expanded":s,"aria-haspopup":"dialog",onClick:()=>u(p=>!p),"data-testid":`ribbon-tab-${l.id}`,"data-kit-ui-id":fi(l),children:l.label}),h.jsx(e0,{open:s,anchor:c,onClose:()=>u(!1),label:l.label,className:"kui-drop-ribbon",testId:`ribbon-drop-${l.id}`,children:h.jsx(Au,{className:"kui-drop-ribbon-strip",panelClassName:"kui-ribbon-panel",resetKey:l.id,labels:{start:o("ribbonScrollStart"),end:o("ribbonScrollEnd")},testId:`ribbon-drop-${l.id}-scroll`,children:h.jsx("fieldset",{className:"kui-element",disabled:d.disabled,children:h.jsx(Ut.Provider,{value:"full",children:l.ribbon})})})})]})}function KA({tabs:l,menus:s}){const{t:u,testId:c}=Ne();return h.jsx("nav",{className:"kui-menu-nav","aria-label":u("menuBar"),"data-testid":`${c}-menu-bar`,children:h.jsx(Au,{className:"kui-menu-strip",panelClassName:"kui-menu-bar",labels:{start:u("menusScrollStart"),end:u("menusScrollEnd")},testId:`${c}-menu-bar-scroll`,children:l.map(f=>f.menu?h.jsxs(xs,{trigger:({toggle:o,open:d})=>h.jsx("button",{type:"button",className:"kui-menu-bar-item","aria-expanded":d,onClick:o,"data-testid":`${c}-menu-${f.id}`,"data-kit-ui-id":`menu:${f.id}`,children:f.label}),children:[h.jsx(TA,{tree:f.menu,nodes:s.get(f.id)??[]}),h.jsx(Lu,{place:`menu:${f.id}`,as:"menu"})]},f.id):h.jsx(XA,{tab:f},f.id))})})}function IA(l,s){if(l<=0)return zs;const u=s.length,c=Math.min(u,l-1),f=Math.min(u,Math.max(0,l-1-u)),o=d=>new Set(s.slice(u-d));return{size:c===u&&u>0?"icon":"small",icons:o(c),collapsed:o(f)}}function ZA(l){return 1+2*l}function z0(l){return[...l.querySelectorAll("[data-ribbon-group]")].filter(s=>!s.closest(".kui-drop-panel"))}function FA(l){return z0(l).map(s=>s.dataset.ribbonGroup??"")}function t5(l){return z0(l).reduce((s,u)=>s+u.offsetWidth,0)}function QA({mode:l,tab:s,nodes:u,panel:c,measure:f}){const{t:o}=Ne(),d=ya(),p=s.ribbon??(s.menu?h.jsx(jA,{tab:s,nodes:u}):null),y=w.useCallback(N=>o("lineMore",{group:N}),[o]),g=l==="line",v=`${l}:${s.id}`,[b,M]=w.useState({key:v,level:0,groups:[],fresh:0}),z=b.key===v?b.level:0,x=b.key===v?b.groups:[],E=w.useMemo(()=>g?zs:IA(z,x),[x,z,g]),T=w.useRef({width:0,content:0}),C=w.useRef(null);return w.useLayoutEffect(()=>{const N=c.current;if(!g&&N){const G=FA(N);if(N.scrollWidth-N.clientWidth>1&&z<ZA(G.length)){M($=>({key:v,level:z+1,groups:G,fresh:$.fresh}));return}T.current={width:N.clientWidth,content:t5(N)};const J=C.current;if(J){J.disconnect(),J.observe(N);for(const $ of z0(N))J.observe($)}}f(l,N)}),w.useLayoutEffect(()=>{const N=c.current;if(g||!N||typeof ResizeObserver>"u")return;const G=new ResizeObserver(()=>{const J=T.current;(N.clientWidth>J.width+1||Math.abs(t5(N)-J.content)>1)&&M($=>({key:v,level:0,groups:$.groups,fresh:$.fresh+1}))});return C.current=G,G.observe(N),()=>{G.disconnect(),C.current=null}},[v,g,c]),p?h.jsx(Au,{className:g?"kui-line":"kui-ribbon-body",panelClassName:g?"kui-line-panel":"kui-ribbon-panel",role:"tabpanel",resetKey:s.id,labels:{start:o("ribbonScrollStart"),end:o("ribbonScrollEnd")},testId:"ribbon-scroll",panelRef:c,children:h.jsx("fieldset",{className:"kui-element",disabled:d.state(fi(s)).disabled,children:h.jsx(ng.Provider,{value:y,children:h.jsx(Ut.Provider,{value:g?"line":"full",children:h.jsx(dl.Provider,{value:E,children:p})})})})}):null}function JA({tabs:l,tab:s,onTab:u,defaultTab:c,title:f,actions:o,options:d,rail:p,sidebar:y,panels:g,focusTool:v,statusBar:b=!0,children:M,...z}){const x=Ne(),{host:E,phrase:T,testId:C}=x,N=ya(),G=w.useRef(null),J=w.useRef(null),$=E.readOnly===!0,le=UA(),Z=N.config.add,ie=w.useMemo(()=>{if(!l.some(U=>U.menu))return l;const j=Z.map(U=>U.place).filter(U=>U.startsWith("menu:")&&!U.includes("/")).map(U=>U.slice(5)).filter((U,Q,ve)=>ve.indexOf(U)===Q&&!l.some(Se=>Se.id===U));return j.length?[...l,...j.map(U=>({id:U,label:T(U),menu:{rows:[]}}))]:l},[Z,T,l]),se=kA(ie),ae=ie.filter(j=>{var U,Q;return N.state(fi(j)).hidden||$&&!j.view?!1:!j.menu||j.ribbon?!0:(((U=se.get(j.id))==null?void 0:U.length)??0)>0||(((Q=j.menu.before)==null?void 0:Q.length)??0)>0||N.buttons(`menu:${j.id}`).length>0}),de=HA(E,ae.length>0),[q,ue]=w.useState(c??null),we=s??q,D=ae.find(j=>j.id===we)??ae.find(j=>j.id===c)??ae.find(j=>j.id.toLowerCase()!=="file")??ae[0]??null,L=(D==null?void 0:D.id)??null,P=w.useCallback(j=>{ue(j),u==null||u(j)},[u]);w.useLayoutEffect(()=>{s!==void 0&&L!==null&&L!==s&&(u==null||u(L))},[L,u,s]);const re=_A(G,de.chosen,L??"",de.allowed),pe=de.focus?"focus":re.effective,I=j=>(ju()?j.metaKey:j.ctrlKey)&&!j.shiftKey&&!j.altKey&&j.code==="Backslash"?!de.allowed.includes("focus")||N.state("action:mode").denied?!1:(de.toggleFocus(),!0):!1,ye=()=>de.focus?(de.exitFocus(),!0):!1,te=pe==="focus",oe=w.useRef(te);w.useLayoutEffect(()=>{var U,Q;if(oe.current===te)return;oe.current=te;const j=document.activeElement;j&&j!==document.body&&j.isConnected||(Q=(te?null:(U=G.current)==null?void 0:U.querySelector(".kui-mode-button"))??G.current)==null||Q.focus({preventScroll:!0})},[te]);const k=te?h.jsx(SA,{tool:v,onExit:de.exitFocus}):h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"kui-frame-top","data-testid":`${C}-top-bar`,children:[f?h.jsx("div",{className:"kui-frame-title",children:f}):null,pe==="menus"?h.jsx(KA,{tabs:ae,menus:se}):h.jsx(YA,{tabs:ae,active:L,onTab:P}),h.jsx("div",{className:"kui-ribbon-end",children:h.jsx(Zk,{before:o,mode:h.jsx(NA,{display:de,shown:pe,areas:ae.length>0})})})]}),(pe==="line"||pe==="classic")&&D?h.jsx(QA,{mode:pe,tab:D,nodes:se.get(D.id)??[],panel:J,measure:re.measure}):null,d?h.jsx(Wk,{children:d}):null]});return h.jsx(Vg.Provider,{value:pe,children:h.jsx(BA.Provider,{value:de,children:h.jsx(Qk,{...z,statusBar:b&&!te,top:k,frame:{ref:G,mode:pe,chosen:de.chosen,touch:le,viewOnly:$,keyDown:I,escape:ye},children:h.jsxs("div",{className:"kui-frame-body",children:[p&&!$&&!te?p:null,y&&!te?y:null,h.jsx("div",{className:"kui-frame-main",children:M}),g&&!te?g:null]})})})})}const Z1=Object.freeze({accent:"#5645d4",surface:"#ffffff",ink:"#1f1d2b",font:"11px ui-sans-serif, system-ui, sans-serif",marquee:{fill:null,fillOpacity:.08,stroke:null,width:1,dash:[4,3],inside:!1},path:{minWidth:1,dash:[4,3]},line:{width:1,dash:[4,3]},anchor:{shape:"square",radius:0,size:6,fill:null,ringWidth:1},handle:{radius:3,fill:null,ringWidth:0},label:{font:null,dx:4,dy:-4},measure:{fill:null,color:null,font:null,padX:6,height:18,padY:2,radius:4,dx:12,dy:12,align:"start"},swatch:{size:12,radius:3,ringWidth:2,ring:null,selectedRing:null}});function PA(l){if(!l)return Z1;const s=Z1,u={...s};for(const[c,f]of Object.entries(l)){if(f===void 0)continue;const o=s[c];u[c]=o&&typeof o=="object"&&!Array.isArray(o)?{...o,...f}:f}return u}function cl([l,s,u,c]){return`rgba(${l}, ${s}, ${u}, ${c/255})`}function WA(l){const s=/(\d+(?:\.\d+)?)px/.exec(l);return s?Number(s[1]):11}function ej(l,s,u,c,f){const o=f.measure,d=o.font??f.font,p=o.fill??f.ink;l.font=d;const y=l.measureText(c).width+o.padX*2,g=o.height??Math.round(WA(d)*1.2)+o.padY*2,v=o.align==="center"?s-y/2:s;l.fillStyle=p,l.beginPath(),l.roundRect(v,u,y,g,o.radius),l.fill(),l.fillStyle=o.color??(p===f.surface?f.ink:f.surface),l.textBaseline="middle",l.fillText(c,v+o.padX,u+g/2)}function n5(l,s,u,c,f){switch(c.kind){case"marquee":{const o=f.marquee,d=s(c.x0,c.y0),p=s(c.x1,c.y1);if(l.save(),l.globalAlpha*=o.fillOpacity,l.fillStyle=o.fill??f.accent,l.fillRect(d.x,d.y,p.x-d.x,p.y-d.y),l.restore(),l.strokeStyle=o.stroke??f.accent,l.lineWidth=o.width,l.setLineDash(o.dash),o.inside){const y=o.width/2,[g,v]=[Math.min(d.x,p.x),Math.max(d.x,p.x)],[b,M]=[Math.min(d.y,p.y),Math.max(d.y,p.y)];l.strokeRect(g+y,b+y,Math.max(0,v-g-o.width),Math.max(0,M-b-o.width))}else l.strokeRect(d.x+.5,d.y+.5,p.x-d.x,p.y-d.y);break}case"path":{const o=s(0,0);l.translate(o.x,o.y),l.scale(u.zoom,u.zoom),l.lineWidth=Math.max(c.width,f.path.minWidth)/u.zoom,c.dashed&&l.setLineDash(f.path.dash.map(d=>d/u.zoom)),l.strokeStyle=cl(c.color),l.stroke(new Path2D(c.d));break}case"line":{const o=s(c.ax,c.ay),d=s(c.bx,c.by);l.lineWidth=f.line.width,c.dashed&&l.setLineDash(f.line.dash),l.strokeStyle=cl(c.color),l.beginPath(),l.moveTo(o.x,o.y),l.lineTo(d.x,d.y),l.stroke();break}case"anchor":{const o=f.anchor,d=s(c.x,c.y),p=c.size||o.size,y=cl(c.color);if(l.fillStyle=c.filled?y:o.fill??f.surface,l.strokeStyle=y,l.lineWidth=o.ringWidth,o.shape==="circle")l.beginPath(),l.arc(d.x,d.y,p/2,0,Math.PI*2),l.fill(),o.ringWidth>0&&(l.beginPath(),l.arc(d.x,d.y,Math.max(0,p/2-o.ringWidth/2),0,Math.PI*2),l.stroke());else if(o.radius>0){const g=Math.round(d.x-p/2),v=Math.round(d.y-p/2),b=o.ringWidth/2;l.beginPath(),l.roundRect(g,v,p,p,o.radius),l.fill(),o.ringWidth>0&&(l.beginPath(),l.roundRect(g+b,v+b,p-o.ringWidth,p-o.ringWidth,Math.max(0,o.radius-b)),l.stroke())}else{const g=Math.round(d.x-p/2),v=Math.round(d.y-p/2);l.fillRect(g,v,p,p),o.ringWidth>0&&l.strokeRect(g+o.ringWidth/2,v+o.ringWidth/2,p-o.ringWidth,p-o.ringWidth)}break}case"handle":{const o=f.handle,d=s(c.x,c.y),p=cl(c.color);l.fillStyle=o.fill??p,l.beginPath(),l.arc(d.x,d.y,o.radius,0,Math.PI*2),l.fill(),o.ringWidth>0&&(l.strokeStyle=p,l.lineWidth=o.ringWidth,l.stroke());break}case"label":{const o=s(c.x,c.y);l.font=f.label.font??f.font,l.fillStyle=cl(c.color),l.fillText(c.text,o.x+f.label.dx,o.y+f.label.dy);break}case"measure":{const o=s(c.x,c.y);ej(l,o.x+f.measure.dx,o.y+f.measure.dy,c.text,f);break}case"highlight":{l.fillStyle=cl(c.color),l.beginPath(),c.quad.forEach(([o,d],p)=>{const y=s(o,d);p===0?l.moveTo(y.x,y.y):l.lineTo(y.x,y.y)}),l.closePath(),l.fill();break}case"swatch":{const o=f.swatch,d=s(c.x,c.y);l.fillStyle=cl(c.color),l.strokeStyle=c.selected?o.selectedRing??f.accent:o.ring??f.surface,l.lineWidth=o.ringWidth,l.beginPath(),l.roundRect(d.x-o.size/2,d.y-o.size/2,o.size,o.size,o.radius),l.fill(),l.stroke();break}}}function aj(l,s=Z1,u){return(c,f,o)=>{const d={};l.forEach((p,y)=>{const g=()=>{c.lineWidth=1,c.setLineDash([])};c.save();try{g();let v=!1;u&&(v=u(p,{context:c,toScreen:f,view:o,style:s,overlays:l,index:y,frame:d,drawDefault:(b=p)=>{c.save();try{g(),n5(c,f,o,b,s)}finally{c.restore()}}})===!0),v||(c.restore(),c.save(),g(),n5(c,f,o,p,s))}finally{c.restore()}})}}const tj=()=>!1;function S1(l){return{shift:l.shift,alt:l.alt,command:l.meta,control:!1,space:!1}}const nj=new Set(["Delete","Backspace"]),l5=new Set(["Enter","Escape","Backspace","Delete","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Tab","Home","End"]);function lj(l,s,u,c){var Oe,je;const[f,o]=w.useState([]),[d,p]=w.useState(c.initial),[y,g]=w.useState(()=>tj),[v,b]=w.useState(null),[M,z]=w.useState(null),x=w.useRef(c);x.current=c;const E=w.useRef(y);E.current=y;const T=w.useRef(0),C=w.useRef(null),[N,G]=w.useState(0),J=w.useRef(c.initial),$=w.useRef(null),le=Object.keys(c.hostTools??{}).find(H=>{var F;return((F=c.hostTools)==null?void 0:F[H])===Dt})??Dt.id;let Z=d;y(d)&&(Z=((Oe=f.find(H=>{var F;return!((F=c.hidden)!=null&&F.has(H.id))&&!y(H.id)}))==null?void 0:Oe.id)??le,f.length&&Z!==d&&p(Z));const ie=((je=c.hostTools)==null?void 0:je[Z])??(Z===Dt.id&&!f.some(H=>H.id===Z)?Dt:void 0);J.current=Z;const se=w.useRef(new Set);se.current=new Set(Object.keys(c.hostTools??{})),f.some(H=>H.id===Dt.id)||se.current.add(Dt.id);const ae=w.useCallback(H=>{if(E.current(H))return;const F=++T.current;C.current=F,J.current=H,G(F),p(H)},[]),de=w.useCallback(H=>g(()=>H),[]),q=w.useRef(1),ue=w.useRef(null),we=w.useRef(!1),D=w.useRef([]),L=w.useRef(null),P=w.useCallback((H,F)=>{var me,ze;if(!H)return;L.current=H,b(H);let ce=null;for(const ke of H.requests)ke.kind==="switchTool"?(C.current===null||F===C.current)&&!E.current(ke.id)&&(ce=ke.id):ke.kind==="status"?z(ke.text):(ze=(me=x.current).onDialog)==null||ze.call(me,ke.name,ke.params);ce!==null&&ce!==J.current&&(J.current=ce,$.current={id:ce,serial:T.current},se.current.has(ce)||D.current.unshift({name:"selectTool",args:[ce,q.current],settled:!0,coalesce:!1,selection:F}),p(ce))},[]),re=w.useRef(!1),pe=w.useRef(null),I=w.useCallback((H,F)=>{const ce=document.activeElement??document.body;re.current=!0,pe.current=0;try{ce.dispatchEvent(new KeyboardEvent("keydown",{key:H,code:ij(H),shiftKey:F,bubbles:!0,cancelable:!0}))}finally{re.current=!1,pe.current=null}},[]),ye=w.useCallback(H=>{pe.current===null?D.current.push(H):D.current.splice(pe.current++,0,H)},[]),te=w.useCallback(async()=>{var H;if(!we.current){we.current=!0;try{for(let F=D.current.shift();F;F=D.current.shift()){if("work"in F){await F.work();continue}if("key"in F){F.key.length>1?I(F.key,F.shift):(H=L.current)!=null&&H.wantsText?P(await l("toolText",[F.key,q.current],!0).catch(()=>null)):x.current.onDeferredKey?x.current.onDeferredKey(F.key,F.shift):I(F.key,F.shift);continue}P(await l(F.name,F.args,F.settled).catch(()=>null),F.selection),F.selection===C.current&&(C.current=null)}}finally{we.current=!1}}},[P,I,l]),oe=w.useCallback((H,F,ce,me=!1,ze)=>{const ke=D.current[D.current.length-1];me&&pe.current===null&&ke&&"name"in ke&&ke.coalesce&&ke.name===H?D.current[D.current.length-1]={name:H,args:F,settled:ce,coalesce:me,selection:ze}:ye({name:H,args:F,settled:ce,coalesce:me,selection:ze}),te()},[ye,te]),k=w.useCallback(H=>!we.current&&!D.current.length?H():new Promise((F,ce)=>{ye({work:()=>H().then(F,ce)}),te()}),[ye,te]);w.useEffect(()=>FT(l,k),[k,l]),w.useEffect(()=>{s&&l("tools").then(H=>o(H??[]))},[s,l]);const j=!!ie;w.useEffect(()=>{if(!s){$.current=null;return}if(j)return;const H=$.current;$.current=null,!((H==null?void 0:H.id)===Z&&H.serial===N)&&oe("selectTool",[Z,q.current],!0,!1,N)},[Z,j,s,N,oe]),w.useEffect(()=>{if(!s||j)return;const H=ue.current??{x:0,y:0};oe("toolState",[H.x,H.y,"{}",q.current],!1,!0)},[u.revision,s]);const U=w.useCallback((H,F,ce,me,ze=!1)=>{q.current=ce,ue.current={x:F.x,y:F.y},oe("pointer",[JSON.stringify({action:H,x:F.x,y:F.y,mods:S1(F),pressure:F.pressure,zoom:ce})],me,ze)},[oe]),Q=w.useMemo(()=>ie??{id:Z,cursor:(v==null?void 0:v.cursor)||"default",begin:(H,{viewport:F})=>(U("down",H,F.view.zoom,!1),{move:(ce,me)=>U("drag",ce,me.viewport.view.zoom,!1,!0),end:(ce,me)=>U("up",ce,me.viewport.view.zoom,!0),cancel:ce=>oe("toolKey",["Escape","{}",ce.viewport.view.zoom],!0)}),hover:(H,{viewport:F})=>U("move",H,F.view.zoom,!1,!0),doubleClick:(H,{viewport:F})=>U("doubleClick",H,F.view.zoom,!0)},[Z,ie,U,v==null?void 0:v.cursor,oe]),ve=v==null?void 0:v.overlays,{overlayStyle:Se,drawOverlay:Le}=c,ge=sj(),Te=w.useMemo(()=>{const H=PA(Se);return ge&&!(Se!=null&&Se.accent)?{...H,accent:ge}:H},[ge,Se]),Ha=w.useMemo(()=>ve!=null&&ve.length&&!ie?Nk(aj(ve,Te,Le)):null,[Le,ie,ve,Te]),Vt=w.useCallback(H=>{if(ie||!H.shiftKey&&!H.altKey&&!H.metaKey&&!H.ctrlKey&&H.key==="Escape"&&x.current.escapable&&!x.current.escapable())return!1;const F=H.metaKey||H.ctrlKey,ce=H.key.length===1||nj.has(H.key);if(!F&&!H.altKey&&ce&&!re.current&&(we.current||D.current.length))return D.current.push({key:H.key,shift:H.shiftKey}),te(),!0;const me=L.current;if(!me)return!1;if(me.wantsText&&!F){if(H.key.length===1)oe("toolText",[H.key,q.current],!0);else if(l5.has(H.key))oe("toolKey",[H.key,JSON.stringify(S1({shift:H.shiftKey,alt:H.altKey,meta:!1})),q.current],!0);else return!1;return!0}return me.busy&&l5.has(H.key)?(oe("toolKey",[H.key,JSON.stringify(S1({shift:H.shiftKey,alt:H.altKey,meta:F})),q.current],!0),!0):!1},[ie,te,oe]),ne=w.useCallback((H,F)=>{const ce=(F?`Shift+${H}`:H).toLowerCase(),me=f.filter(ke=>{var We;return!((We=x.current.hidden)!=null&&We.has(ke.id))}).filter(ke=>{var We;return((We=ke.shortcut)==null?void 0:We.toLowerCase())===ce});if(!me.length)return null;const ze=me.findIndex(ke=>ke.id===Z);return me[(ze+1)%me.length].id},[Z,f]),he=w.useCallback(()=>{if(j)return;const H=ue.current??{x:0,y:0};oe("toolState",[H.x,H.y,"{}",q.current],!1,!0)},[j,oe]),Ee=w.useCallback(H=>{if(!Number.isFinite(H)||H<=0||Math.abs(H-q.current)<1e-9||(q.current=H,!s||j||!L.current))return;const F=ue.current??{x:0,y:0};oe("toolState",[F.x,F.y,"{}",H],!1,!0)},[j,s,oe]),xe=w.useCallback(H=>{H&&oe("toolText",[H,q.current],!0)},[oe]);return{tools:f,active:Z,select:ae,setDenied:de,refresh:he,viewZoom:Ee,typeText:xe,canvasTool:Q,decorate:Ha,status:M,wantsText:!!(v!=null&&v.wantsText)&&!ie,keyDown:Vt,toolForKey:ne}}function ij(l){return/^[a-z]$/i.test(l)?`Key${l.toUpperCase()}`:/^[0-9]$/.test(l)?`Digit${l}`:l==="Delete"||l==="Backspace"?l:{".":"Period",",":"Comma","/":"Slash",";":"Semicolon","'":"Quote","[":"BracketLeft","]":"BracketRight","-":"Minus","=":"Equal","`":"Backquote","\\":"Backslash"," ":"Space"}[l]??""}function sj(){const l=()=>typeof document>"u"?null:getComputedStyle(document.documentElement).getPropertyValue("--kit-primary").trim()||null,[s,u]=w.useState(l);return w.useEffect(()=>{if(typeof MutationObserver>"u")return;const c=new MutationObserver(()=>u(l()));return c.observe(document.documentElement,{attributes:!0,attributeFilter:["style","data-color-scheme","data-brand","class"]}),u(l()),()=>c.disconnect()},[]),s}const wu=l=>l.replace(/\\(.)/g,(s,u)=>u==="n"?`
51
51
  `:u==="t"?" ":u);function rj(l){const s=new Map;for(const u of l.split(`
52
- `)){if(!u.trim()||u.startsWith("#"))continue;const[,c,f]=u.split(" ");c&&f&&s.set(wu(c),wu(f.replace(/\r$/,"")))}return s}function uj(l){const s=new Map;for(const u of l.matchAll(/"((?:[^"\\]|\\.)*)"\s*=>\s*"((?:[^"\\]|\\.)*)"/g))s.set(wu(u[1]),wu(u[2]));return s}function qg(l){const s=l.toLowerCase(),[u,c]=s.split("-"),f=[s];return u==="zh"&&f.push(["tw","hk","mo","hant"].includes(c??"")?"zh-hant":"zh-hans"),u==="sr"&&s.includes("latn")&&f.push("sr-latn"),f.push(u),f}async function cj(l,s){const u=new Map(Object.entries(l).map(([y,g])=>[y.split("/").pop().replace(/\.(tsv|rs)$/,"").toLowerCase(),{path:y,load:g}])),c=qg(s).find(y=>u.has(y));if(!c||s.toLowerCase().startsWith("en"))return y=>y;const{path:f,load:o}=u.get(c),d=String(await o()),p=f.endsWith(".rs")?uj(d):rj(d);return y=>p.get(y)??y}function oj(l,s,u){var o;const c=qg(u).concat(u).find(d=>Object.keys(s).some(p=>p.toLowerCase()===d)),f=c?(o=Object.entries(s).find(([d])=>d.toLowerCase()===c))==null?void 0:o[1]:void 0;return!f||u.toLowerCase().startsWith("en")?l:d=>f[d]??l(d)}sk({"anchored.release":nu,"conveyor.collect":H4,"index.generate":j1,"layout.detachAll":nu,"library.json":Ix,"math.svg":h0,"object.attributes":tu,"object.bevel":kC,"object.content":k1,"object.directionalFeather":dm,"object.dropShadow":di,"object.feather":dm,"object.fit":u0,"object.innerGlow":RE,"object.innerShadow":xE,"object.label":Q4,"object.outerGlow":OE,"object.pathfinder":EE,"object.satin":W4,"object.setFlags":T4,"script.run":CE,"select.container":ps,"select.content":k1,"select.firstAbove":t0,"select.lastBelow":I4,"states.release":nu,"transform.shear":tE,"xml.loadDtd":wC,"xml.structure":uC,"xref.formats":oi,"xref.setFormat":oi});const i5=/^#[0-9a-f]{6}$/i;function Gg(l=document.documentElement){const s=getComputedStyle(l).getPropertyValue("--kit-canvas").trim();if(i5.test(s))return s.toLowerCase();if(!s||typeof CSS>"u"||!CSS.supports("color",s))return null;const u=document.createElement("canvas").getContext("2d");if(!u)return null;u.fillStyle=s;const c=String(u.fillStyle);return i5.test(c)?c.toLowerCase():null}function fj(l,s){w.useEffect(()=>{if(!l)return;let u=!0,c=null;const f=()=>{const d=Gg();!d||d===c||(c=d,l.invoke("setBackdrop",d).then(()=>{var p;return u?(p=s.current)==null?void 0:p.retryRender():void 0}).catch(()=>{}))};f();const o=typeof MutationObserver>"u"?null:new MutationObserver(f);return o==null||o.observe(document.documentElement,{attributes:!0,attributeFilter:["style","data-color-scheme","class"]}),()=>{u=!1,o==null||o.disconnect()}},[l,s])}const dj=["DroidSansFallbackFull.ttf","Inter-Variable.ttf","Lora-Variable.ttf","JetBrainsMono-Variable.ttf","BricolageGrotesque-Variable.ttf"];function hj(){const l=Gg();return{kitId:"kit.layout",base:new URL("./engine/",document.baseURI).href,module:"kition_layout_kit",documentClass:"LayoutDocument",setup:l?[{method:"setBackdrop",args:[l]}]:[],fonts:dj.map(s=>new URL(`./fonts/${s}`,document.baseURI).href)}}const mj={summary:"{pages} pages",summaryOne:"{pages} page",selectedCount:"{count} selected",addPage:"Add page",newLayer:"New layer",hideLayer:"Hide layer",showLayer:"Show layer",lockLayer:"Lock layer",unlockLayer:"Unlock layer",nothingSelected:"Select an object or text to see its properties.",positionX:"X position",positionY:"Y position",width:"Width",height:"Height",rotation:"Rotation",flipHorizontal:"Flip horizontal",flipVertical:"Flip vertical",tint:"Tint",strokeWeight:"Weight",cornerRadius:"Corner radius",fontSize:"Size",fontStyle:"Style",leading:"Leading",auto:"auto",tracking:"Tracking",alignment:"Alignment","align.left":"Align left","align.center":"Align center","align.right":"Align right","align.justify":"Justify",parentItems:"{count} objects",noParent:"[None]",newParent:"New parent",pageParent:"Parent of the page",movePageUp:"Move page up",movePageDown:"Move page down",duplicateSpread:"Duplicate spread",deletePage:"Delete page",collapse:"Collapse",expand:"Expand",renameLayer:"Layer name",renameObject:"Object name",hideObject:"Hide object",showObject:"Show object",lockObject:"Lock object",unlockObject:"Unlock object",layerUp:"Move layer up",layerDown:"Move layer down",swatchTarget:"Apply to",newSwatch:"New swatch",deleteSwatch:"Delete swatch",swatchName:"Name",swatchNameHint:"Named after its value",swatchColor:"Color",cancel:"Cancel",ok:"OK",newParagraphStyle:"New paragraph style from the selection",newCharacterStyle:"New character style from the selection",newParagraphStyleName:"Paragraph Style",newCharacterStyleName:"Character Style",editStyle:"Edit style",deleteStyle:"Delete style",styleOptions:"Style options: {name}",styleName:"Style name",unchanged:"As it is",noLinks:"No placed graphics.",goToLink:"Select its frames",relink:"Relink",placeImage:"Place image",placePurpose:"Place an image",relinkPurpose:"Relink {name}",ppi:"{ppi} ppi","link.ok":"Linked","link.modified":"Modified","link.missing":"Missing","link.embedded":"Embedded",documentSetup:"Document setup",presets:"Sizes","preset.letter":"Letter","preset.a4":"A4","preset.poster":"Poster","preset.square":"Square","preset.story":"Story","preset.landscape":"Landscape","presetSize.letter":"8.5 × 11 in","presetSize.a4":"210 × 297 mm","presetSize.poster":"1080 × 1440 px","presetSize.square":"1080 × 1080 px","presetSize.story":"1080 × 1920 px","presetSize.landscape":"1920 × 1080 px",presetCustom:"Page size: {size}",units:"Units","unit.pt":"Points","unit.px":"Pixels","unit.mm":"Millimeters","unit.in":"Inches",intent:"Intent","intent.print":"Print","intent.web":"Web","intent.mobile":"Mobile",margins:"Margins",bleed:"Bleed",columns:"Columns",gutter:"Gutter",facingPages:"Facing pages",export:"Export",exportAction:"Export",exported:"Exported {count} files",exportFailed:"Could not export",format:"Format","format.png":"PNG image","format.jpeg":"JPEG image","format.pdf":"PDF","format.idml":"InDesign Markup (IDML)","format.epub":"EPUB","format.html":"HTML",pages:"Pages",allPages:"All pages ({count})",currentPage:"Page {page}",pageRange:"Range",includeBleed:"Include bleed",resolution:"Resolution",scale:"{scale}× ({ppi} ppi)",transparentBackground:"Transparent background",quality:"Quality",exportMenu:"Export…",documentSetupMenu:"Document Setup…",sizes:"Sizes",newSize:"New size",deleteSize:"Delete size",originalSize:"Original",sizeOf:"{width} × {height}",sizeName:"Name",sizeNameTaken:"A size with this name exists.",sizeNote:"A copy of the original at this size; objects follow their liquid rules.",allSizes:"Every size ({count})",pageBackground:"Page background",backgroundColor:"Background color",noBackground:"None (transparent)",templates:"New from Template",templatesMenu:"New from Template…",templatesNote:"Replaces the pages, swatches and styles of this document. Undo brings them back.","template.editorial":"Editorial","template.event":"Event","template.sale":"Promotion","template.quote":"Quote",homeTab:"Home","home.frames":"Frames","home.place":"Place Image","home.styles":"Styles","home.output":"Output"},vj={summary:"{pages} 页",summaryOne:"{pages} 页",selectedCount:"已选 {count} 个",addPage:"添加页面",newLayer:"新建图层",hideLayer:"隐藏图层",showLayer:"显示图层",lockLayer:"锁定图层",unlockLayer:"解锁图层",nothingSelected:"选择一个对象或一段文字以查看其属性。",positionX:"X 位置",positionY:"Y 位置",width:"宽度",height:"高度",rotation:"旋转角度",flipHorizontal:"水平翻转",flipVertical:"垂直翻转",tint:"色调",strokeWeight:"粗细",cornerRadius:"圆角半径",fontSize:"字号",fontStyle:"字体样式",leading:"行距",auto:"自动",tracking:"字距",alignment:"对齐","align.left":"左对齐","align.center":"居中对齐","align.right":"右对齐","align.justify":"两端对齐",parentItems:"{count} 个对象",noParent:"[无]",newParent:"新建主页",pageParent:"页面的主页",movePageUp:"上移页面",movePageDown:"下移页面",duplicateSpread:"直接复制跨页",deletePage:"删除页面",collapse:"折叠",expand:"展开",renameLayer:"图层名称",renameObject:"对象名称",hideObject:"隐藏对象",showObject:"显示对象",lockObject:"锁定对象",unlockObject:"解锁对象",layerUp:"上移图层",layerDown:"下移图层",swatchTarget:"应用于",newSwatch:"新建色板",deleteSwatch:"删除色板",swatchName:"名称",swatchNameHint:"以颜色值命名",swatchColor:"颜色",cancel:"取消",ok:"确定",newParagraphStyle:"用所选内容新建段落样式",newCharacterStyle:"用所选内容新建字符样式",newParagraphStyleName:"段落样式",newCharacterStyleName:"字符样式",editStyle:"编辑样式",deleteStyle:"删除样式",styleOptions:"样式选项:{name}",styleName:"样式名称",unchanged:"保持不变",noLinks:"没有置入的图形。",goToLink:"选择其框架",relink:"重新链接",placeImage:"置入图像",placePurpose:"置入一张图像",relinkPurpose:"重新链接 {name}",ppi:"{ppi} ppi","link.ok":"已链接","link.modified":"已修改","link.missing":"缺失","link.embedded":"已嵌入",documentSetup:"文档设置",presets:"尺寸","preset.letter":"Letter","preset.a4":"A4","preset.poster":"海报","preset.square":"方形","preset.story":"快拍","preset.landscape":"横幅","presetSize.letter":"8.5 × 11 英寸","presetSize.a4":"210 × 297 毫米","presetSize.poster":"1080 × 1440 像素","presetSize.square":"1080 × 1080 像素","presetSize.story":"1080 × 1920 像素","presetSize.landscape":"1920 × 1080 像素",presetCustom:"页面大小:{size}",units:"单位","unit.pt":"点","unit.px":"像素","unit.mm":"毫米","unit.in":"英寸",intent:"用途","intent.print":"打印","intent.web":"Web","intent.mobile":"移动设备",margins:"边距",bleed:"出血",columns:"栏数",gutter:"栏间距",facingPages:"对页",export:"导出",exportAction:"导出",exported:"已导出 {count} 个文件",exportFailed:"无法导出",format:"格式","format.png":"PNG 图像","format.jpeg":"JPEG 图像","format.pdf":"PDF","format.idml":"InDesign 标记 (IDML)","format.epub":"EPUB","format.html":"HTML",pages:"页面",allPages:"全部页面({count})",currentPage:"第 {page} 页",pageRange:"范围",includeBleed:"包含出血",resolution:"分辨率",scale:"{scale}×({ppi} ppi)",transparentBackground:"透明背景",quality:"品质",exportMenu:"导出…",documentSetupMenu:"文档设置…",sizes:"尺寸",newSize:"新建尺寸",deleteSize:"删除尺寸",originalSize:"原始",sizeOf:"{width} × {height}",sizeName:"名称",sizeNameTaken:"已有同名尺寸。",sizeNote:"按此尺寸复制原始版面;对象按其自适应规则调整。",allSizes:"全部尺寸({count})",pageBackground:"页面背景",backgroundColor:"背景颜色",noBackground:"无(透明)",templates:"从模板新建",templatesMenu:"从模板新建…",templatesNote:"将替换本文档的页面、色板和样式。撤销可恢复。","template.editorial":"社论","template.event":"活动","template.sale":"促销","template.quote":"引言",homeTab:"开始","home.frames":"框架","home.place":"置入图像","home.styles":"样式","home.output":"输出"},Yg={"en-US":mj,"zh-CN":vj},pj={"zh-CN":{File:"文件",Edit:"编辑",Layout:"版面",Type:"文字",Object:"对象",Table:"表",View:"视图",Window:"窗口",Help:"帮助",Pages:"页面",Layers:"图层",Swatches:"色板","Paragraph Styles":"段落样式","Character Styles":"字符样式",Selection:"选择","Direct Selection":"直接选择",Page:"页面",Gap:"间隙","Type on a Path":"路径文字","Vertical Type":"直排文字",Line:"直线",Pen:"钢笔",Pencil:"铅笔","Rectangle Frame":"矩形框架","Ellipse Frame":"椭圆框架","Polygon Frame":"多边形框架",Rectangle:"矩形",Ellipse:"椭圆",Polygon:"多边形",Scissors:"剪刀","Free Transform":"自由变换",Rotate:"旋转",Scale:"缩放",Shear:"切变","Gradient Swatch":"渐变色板","Gradient Feather":"渐变羽化",Eyedropper:"吸管",Measure:"度量",Hand:"抓手",Zoom:"缩放显示",Properties:"属性",Fill:"填色",Stroke:"描边",Opacity:"不透明度",Font:"字体","Paragraph Style":"段落样式","Character Style":"字符样式","Document Setup":"文档设置",Group:"编组",Ungroup:"取消编组",Duplicate:"直接复制",Clear:"清除",Links:"链接","<group>":"<组>","<text frame>":"<文本框架>","<image>":"<图像>","<rectangle>":"<矩形>","<ellipse>":"<椭圆>","<polygon>":"<多边形>","<line>":"<直线>","<path>":"<路径>","Show Text Threads":"显示文本串接",Extras:"附注","Fit Text to Frame":"使文本适合框架",Fitting:"适合"}},yj=[0,0,0,0];function gj(l){var c,f,o,d,p;const s=l.inspected,u=((c=s.canvas)==null?void 0:c.spreads)??[];return{spreads:(s.spreads??[]).map((y,g)=>{const v=u[g]??{x:0,y:0,width:l.width,height:l.height},b=(y.pages??[]).map((M,z)=>({index:M.index??z,name:M.name??"",bounds:M.bounds??yj,parent:M.parent??null,margins:M.margins??null,columns:M.columns??1,background:M.background??null}));return{index:y.index??g,area:{x0:v.x,y0:v.y,x1:v.x+v.width,y1:v.y+v.height},pages:b,items:y.items??[],left:b.length?Math.min(...b.map(M=>M.bounds[0])):0}}),pageCount:s.pageCount??0,selected:((o=(f=s.selection)==null?void 0:f.items)==null?void 0:o.length)??0,selection:((d=s.selection)==null?void 0:d.items)??[],editingText:((p=s.selection)==null?void 0:p.text)!=null,layers:s.layers??[],activeLayer:s.activeLayer??null,swatches:s.swatches??[],swatchColors:s.swatchColors??(s.swatches??[]).map(y=>({name:y,kind:"color",color:null,locked:!1})),paragraphStyles:s.paragraphStyles??[],characterStyles:s.characterStyles??[],stories:s.stories??[],parents:s.parents??[],layouts:s.layouts??[],settings:{pageWidth:612,pageHeight:792,facingPages:!1,intent:"print",...s.settings},tool:s.tool??"selection"}}function $g(l,s,u){let c=null,f=Number.POSITIVE_INFINITY;for(const o of l.spreads){const{x0:d,y0:p,x1:y,y1:g}=o.area,v=s<d?d-s:s>y?s-y:0,b=u<p?p-u:u>g?u-g:0,M=Math.hypot(v,b);M<f&&(f=M,c=o)}return c}function Xg(l,s=0,u=[]){var c;for(let f=l.length-1;f>=0;f-=1){const o=l[f];u.push({item:o,depth:s}),(c=o.children)!=null&&c.length&&Xg(o.children,s+1,u)}return u}function Mj(l,s){const u=c=>{for(const f of c){if(f.id===s)return f;const o=f.children?u(f.children):null;if(o)return o}return null};for(const c of l.spreads){const f=u(c.items);if(f)return{item:f,spread:c}}return null}const bj=["File","Edit","Layout","Type","Object","Table","View","Window","Help"],wj={File:["file.package"],Edit:["edit.undo","edit.redo","edit.cut","edit.copy","edit.paste","edit.duplicate","edit.stepAndRepeat","find.find"],Layout:["layout.pages.insert","layout.parents.new","layout.marginsAndColumns","layout.createGuides","toc.generate","layout.section"],Type:["footnote.insert","type.createOutlines","type.changeCase","hyperlink.create","list.define","type.fillWithPlaceholder"],Object:["object.group","object.ungroup","object.bringForward","object.sendBackward","object.fit","object.textFrameOptions","object.dropShadow","object.lock"],Table:["table.insertRowBelow","table.insertColumnRight","table.deleteRow","table.deleteColumn","table.merge","table.unmerge","table.convertFromText"],View:["guide.deleteAll","view.showTextThreads"],Window:["object.textWrap","preflight.run","article.new"]},Kg=["note","colorTheme","contentCollector","contentPlacer"],F1=[...cA,"pdf","psd","eps","svg"];function Sj({info:l}){const{run:s,phrase:u,t:c}=Ne(),f=ml(),{can:o,pick:d}=_g(),p=o&&!f,y=Ln("links.list",{})??[],g=async M=>{const z=await d(c("placePurpose"),F1);z&&await s("file.place",{base64:X1(z.bytes),name:z.name,...M!=null?{frame:M}:{}})},v=async M=>{const z=await d(c("relinkPurpose",{name:M.name}),F1);if(z)for(const x of M.uses)await s("file.place",{base64:X1(z.bytes),name:z.name,frame:x.id})},b=l.selection.length===1?l.selection[0]:void 0;return h.jsxs(_n,{title:u("Links"),defaultOpen:!1,testId:"layout-links",children:[y.length?null:h.jsx("p",{className:"layout-empty",children:c("noLinks")}),y.map(M=>{const z=M.uses.map(x=>x.ppi).filter(x=>x!=null);return h.jsxs("div",{className:"layout-row layout-link-row","data-status":M.status,"data-testid":`layout-link-${M.asset}`,children:[h.jsx("span",{className:"layout-row-text",title:M.name,children:M.name}),h.jsx("span",{className:"layout-badge","data-status":M.status,children:c(`link.${M.status}`)}),z.length?h.jsx("span",{className:"kui-muted layout-count",children:c("ppi",{ppi:Math.round(Math.min(...z))})}):null,h.jsx(Ge,{icon:_C,label:c("goToLink"),onClick:()=>void s("links.goTo",{asset:M.asset}),"data-testid":`layout-link-go-${M.asset}`}),p?h.jsx(Ge,{icon:r0,label:c("relink"),onClick:()=>void v(M),"data-testid":`layout-link-relink-${M.asset}`}):null]},M.asset)}),h.jsx(hi,{end:p?h.jsx(Ge,{icon:O4,label:c("placeImage"),onClick:()=>void g(b),"data-testid":"layout-place-image"}):null})]})}function ol({id:l,primary:s,size:u="large"}){const c=mi(),{phrase:f}=Ne(),o=c==null?void 0:c.tools.find(d=>d.id===l);return o?h.jsx($k,{tool:l,icon:M0(o.icon,l),label:f(o.label),size:u,testId:`layout-home-tool-${l}`,primary:s}):null}function zj({onDialog:l}){const{run:s,enabled:u,phrase:c,t:f,session:o}=Ne(),d=o.state,{can:p,pick:y}=_g(),g=async()=>{const v=await y(f("placePurpose"),F1);if(!v)return;const b=(d==null?void 0:d.selection.length)===1?d.selection[0]:void 0;await s("file.place",{base64:X1(v.bytes),name:v.name,...b!=null?{frame:b}:{}})};return h.jsxs(h.Fragment,{children:[h.jsxs(Rn,{label:f("home.frames"),icon:ps,children:[h.jsx(ol,{id:"type"}),h.jsx(ol,{id:"rectangleFrame"}),h.jsx(ol,{id:"rectangle"}),h.jsx(ol,{id:"line"}),h.jsxs(lu,{children:[h.jsx(ol,{id:"ellipseFrame",size:"small"}),h.jsx(ol,{id:"ellipse",size:"small"}),h.jsx(ol,{id:"pen",size:"small"})]}),h.jsx(St,{icon:O4,label:f("home.place"),size:"large",disabled:!p||!u("file.place"),onClick:()=>void g(),"data-testid":"layout-home-place",primary:!0})]}),h.jsxs(Rn,{label:c("Pages"),icon:hm,children:[h.jsx(si,{command:"layout.pages.insert",params:{count:1},icon:hm,size:"large",primary:!0}),h.jsxs(lu,{children:[h.jsx(si,{command:"layout.parents.new",icon:A1,primary:!0}),h.jsx(St,{icon:Z4,label:f("documentSetupMenu"),onClick:()=>l("setup"),"data-testid":"layout-home-document-setup",primary:!0})]})]}),h.jsxs(Rn,{label:f("home.styles"),icon:O1,children:[h.jsx(qm,{icon:O1,label:c("Paragraph Styles"),size:"large",disabled:!u("style.paragraph.apply"),testId:"layout-home-paragraph-style",primary:!0,children:((d==null?void 0:d.paragraphStyles)??[]).map(v=>h.jsx(Bt,{label:v,onSelect:()=>void s("style.paragraph.apply",{name:v}),testId:`layout-home-paragraph-style-${v}`},v))}),h.jsx(qm,{icon:Tu,label:c("Character Styles"),disabled:!u("style.character.apply"),testId:"layout-home-character-style",children:((d==null?void 0:d.characterStyles)??[]).map(v=>h.jsx(Bt,{label:v,onSelect:()=>void s("style.character.apply",{name:v}),testId:`layout-home-character-style-${v}`},v))})]}),h.jsxs(Rn,{label:c("Arrange"),icon:ys,children:[h.jsx(si,{command:"object.group",icon:ys,size:"large",primary:!0}),h.jsxs(lu,{children:[h.jsx(si,{command:"object.ungroup",icon:ku}),h.jsx(si,{command:"object.bringForward",icon:t0}),h.jsx(si,{command:"object.sendBackward",icon:I4})]})]}),h.jsxs(Rn,{label:f("home.output"),icon:E1,children:[h.jsx(St,{icon:E1,label:f("exportMenu"),size:"large",onClick:()=>l("export"),"data-testid":"layout-home-export",primary:!0}),h.jsx(St,{icon:A1,label:f("templatesMenu"),onClick:()=>l("templates"),"data-testid":"layout-home-templates",primary:!0})]})]})}const ri=26,s5=14,r5=6;function xj({info:l,spread:s}){const{run:u,phrase:c,t:f}=Ne(),o=ml(),[d,p]=w.useState(new Set),[y,g]=w.useState(0),[v,b]=w.useState(null),M=w.useMemo(()=>{const J=Xg((s==null?void 0:s.items)??[]),$=[];for(const le of l.layers){const Z=J.filter(({item:se,depth:ae})=>ae===0&&se.layer===le.id).length;if($.push({kind:"layer",layer:le,count:Z}),d.has(le.id))continue;let ie=!1;for(const se of J)se.depth===0&&(ie=se.item.layer===le.id),ie&&$.push({kind:"item",item:se.item,depth:se.depth})}return $},[d,l.layers,s]),z=new Set(l.selection),x=Math.max(0,Math.floor(y/ri)-r5),E=Math.min(M.length,Math.ceil((y+s5*ri)/ri)+r5),T=l.layers.findIndex(J=>J.id===l.activeLayer),C=(J,$)=>void u(J.shiftKey?"selection.toggle":"selection.set",J.shiftKey?{id:$}:{ids:[$]}),N=J=>{const $=v;b(null),!(!J||!$)&&($.layer?u("layer.set",{id:$.id,name:$.text}):u("object.rename",{id:$.id,name:$.text}))},G=(J,$)=>{const le=$*ri;if(J.kind==="layer"){const{layer:ae}=J,de=!d.has(ae.id);return h.jsxs("div",{className:"layout-row layout-layer-row",style:{top:le},"data-active":ae.id===l.activeLayer,"data-testid":`layout-layer-${ae.id}`,children:[h.jsx(Ge,{icon:ae.visible?vs:ou,label:ae.visible?f("hideLayer"):f("showLayer"),pressed:!ae.visible,disabled:o,onClick:()=>void u("layer.set",{id:ae.id,visible:!ae.visible}),"data-testid":`layout-layer-visibility-${ae.id}`}),h.jsx(Ge,{icon:ae.locked?gs:N1,label:ae.locked?f("unlockLayer"):f("lockLayer"),pressed:ae.locked,disabled:o,onClick:()=>void u("layer.set",{id:ae.id,locked:!ae.locked}),"data-testid":`layout-layer-lock-${ae.id}`}),h.jsx("button",{type:"button",className:"layout-disclosure","aria-expanded":de,"aria-label":f(de?"collapse":"expand"),onClick:()=>p(q=>{const ue=new Set(q);return de?ue.add(ae.id):ue.delete(ae.id),ue}),children:de?h.jsx(ci,{size:13,"aria-hidden":"true"}):h.jsx(ws,{size:13,"aria-hidden":"true"})}),h.jsx("span",{className:"layout-layer-color",style:{background:`rgb(${ae.color.join(",")})`},"aria-hidden":"true"}),v!=null&&v.layer&&v.id===ae.id?h.jsx(ym,{value:v.text,label:f("renameLayer"),onChange:q=>b({...v,text:q}),onDone:N,testId:"layout-rename"}):h.jsx("button",{type:"button",className:"layout-row-name",onClick:()=>void u("layer.activate",{id:ae.id}),onDoubleClick:()=>!o&&b({id:ae.id,layer:!0,text:ae.name}),children:ae.name}),h.jsx("span",{className:"kui-muted layout-count",children:J.count})]},`layer-${ae.id}`)}const{item:Z,depth:ie}=J,se=Z.name||c(Z.kind);return h.jsxs("div",{className:"layout-row layout-item-row",style:{top:le},"data-selected":z.has(Z.id),"data-testid":`layout-object-${Z.id}`,children:[h.jsx(Ge,{icon:Z.hidden?ou:vs,label:Z.hidden?f("showObject"):f("hideObject"),pressed:Z.hidden,disabled:o,onClick:()=>void u("object.setFlags",{ids:[Z.id],hidden:!Z.hidden}),"data-testid":`layout-object-visibility-${Z.id}`}),h.jsx(Ge,{icon:Z.locked?gs:N1,label:Z.locked?f("unlockObject"):f("lockObject"),pressed:Z.locked,disabled:o,onClick:()=>void u("object.setFlags",{ids:[Z.id],locked:!Z.locked}),"data-testid":`layout-object-lock-${Z.id}`}),h.jsx("span",{style:{width:14+ie*12,flex:"none"},"aria-hidden":"true"}),v&&!v.layer&&v.id===Z.id?h.jsx(ym,{value:v.text,label:f("renameObject"),onChange:ae=>b({...v,text:ae}),onDone:N,testId:"layout-rename"}):h.jsx("button",{type:"button",className:"layout-row-name",onClick:ae=>C(ae,Z.id),onDoubleClick:()=>!o&&b({id:Z.id,layer:!1,text:se}),"data-testid":`layout-object-name-${Z.id}`,children:se})]},`item-${Z.id}`)};return h.jsxs(_n,{title:c("Layers"),actions:h.jsx(Ge,{icon:Dn,label:f("newLayer"),disabled:o,onClick:()=>void u("layer.new",{}),"data-testid":"layout-new-layer"}),testId:"layout-layers",children:[h.jsx("div",{className:"layout-virtual",style:{height:Math.min(M.length,s5)*ri},onScroll:J=>g(J.currentTarget.scrollTop),"data-testid":"layout-layer-list","data-rows":M.length,children:h.jsx("div",{style:{height:M.length*ri,position:"relative"},children:M.slice(x,E).map((J,$)=>G(J,x+$))})}),h.jsx(hi,{start:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:cu,label:f("layerUp"),disabled:o||T<=0,onClick:()=>l.activeLayer!=null&&void u("layer.move",{id:l.activeLayer,to:T-1}),"data-testid":"layout-layer-up"}),h.jsx(Ge,{icon:uu,label:f("layerDown"),disabled:o||T<0||T+1>=l.layers.length,onClick:()=>l.activeLayer!=null&&void u("layer.move",{id:l.activeLayer,to:T+1}),"data-testid":"layout-layer-down"})]}),end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:ys,label:c("Group"),disabled:o||l.selection.length<2,onClick:()=>void u("object.group",{ids:l.selection}),"data-testid":"layout-group"}),h.jsx(Ge,{icon:ku,label:c("Ungroup"),disabled:o||!l.selection.length,onClick:()=>void u("object.ungroup",{ids:l.selection}),"data-testid":"layout-ungroup"}),h.jsx(Ge,{icon:di,label:c("Duplicate"),disabled:o||!l.selection.length,onClick:()=>void u("edit.duplicate",{}),"data-testid":"layout-duplicate"}),h.jsx(Ge,{icon:Hn,label:c("Clear"),disabled:o||!l.selection.length,onClick:()=>void u("edit.clear",{}),"data-testid":"layout-delete"})]})})]})}const u5=92;function Cj({spread:l}){const{session:s}=Ne(),{doc:u,change:c}=s,[f,o]=w.useState(null),d=l.area.x1-l.area.x0,p=l.area.y1-l.area.y0,y=Math.min(u5/Math.max(1,d),u5/Math.max(1,p)),g=Math.max(1,Math.round(d*y)),v=Math.max(1,Math.round(p*y));return w.useEffect(()=>{if(!u||!f)return;let b=!1;const M=window.setTimeout(async()=>{var x;const z=await u.render(l.area.x0,l.area.y0,y,g,v).catch(()=>null);b||!z||(f.width=g,f.height=v,(x=f.getContext("2d"))==null||x.putImageData(new ImageData(new Uint8ClampedArray(z.buffer,z.byteOffset,z.byteLength),g,v),0,0))},300);return()=>{b=!0,window.clearTimeout(M)}},[f,c.revision,u,v,y,l.area.x0,l.area.y0,g]),h.jsx("canvas",{ref:o,width:g,height:v,className:"layout-thumb"})}function Ej({info:l,onShow:s,onSetup:u}){var z;const{run:c,phrase:f,t:o}=Ne(),d=ml(),[p,y]=w.useState(0),g=Math.min(p,Math.max(0,l.pageCount-1)),v=l.spreads.find(x=>x.pages.some(E=>E.index===g)),b=((z=v==null?void 0:v.pages.find(x=>x.index===g))==null?void 0:z.parent)??null,M=l.parents.filter(x=>x.label).map(x=>[x.label??"",x.label??""]);return h.jsxs(_n,{title:f("Pages"),actions:h.jsx(Ge,{icon:Dn,label:o("addPage"),disabled:d,onClick:()=>void c("layout.pages.insert",{count:1,after:g}),"data-testid":"layout-add-page"}),testId:"layout-pages-panel",children:[h.jsxs("div",{className:"layout-parents","data-testid":"layout-parents",children:[l.parents.map(x=>h.jsx("span",{className:"layout-parent",title:o("parentItems",{count:x.items}),children:x.label??o("noParent")},x.id)),h.jsx(Ge,{icon:Dn,label:o("newParent"),disabled:d,onClick:()=>void c("layout.parents.new",{}),"data-testid":"layout-new-parent"})]}),h.jsx("div",{className:"layout-spreads",children:l.spreads.map(x=>h.jsxs("div",{className:"layout-spread-cell",children:[h.jsx("button",{type:"button",className:"layout-spread",onClick:()=>s(x),"data-testid":`layout-spread-${x.index}`,children:h.jsx(Cj,{spread:x})}),h.jsx("span",{className:"layout-page-names",children:x.pages.map(E=>h.jsx("button",{type:"button",className:"layout-page-name","data-active":E.index===g,onClick:()=>y(E.index),"data-testid":`layout-page-${E.index}`,children:E.name},E.index))})]},x.index))}),h.jsx("fieldset",{className:"layout-stack layout-fieldset",disabled:d,children:h.jsx(Da,{label:o("pageParent"),value:b??"",choices:[["",o("noParent")],...M],onChange:x=>void c("layout.pages.applyParent",{pages:[g+1],parent:x||null}),testId:"layout-page-parent"})}),h.jsx(hi,{start:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:cu,label:o("movePageUp"),disabled:d||g===0,onClick:()=>void c("layout.pages.move",{from:g,to:g-1}).then(()=>y(g-1)),"data-testid":"layout-page-up"}),h.jsx(Ge,{icon:uu,label:o("movePageDown"),disabled:d||g+1>=l.pageCount,onClick:()=>void c("layout.pages.move",{from:g,to:g+1}).then(()=>y(g+1)),"data-testid":"layout-page-down"})]}),end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:Z4,label:f("Document Setup"),disabled:d,onClick:u,"data-testid":"layout-document-setup"}),h.jsx(Ge,{icon:di,label:o("duplicateSpread"),disabled:d||!v,onClick:()=>v&&void c("layout.pages.duplicateSpread",{spread:v.index}),"data-testid":"layout-duplicate-spread"}),h.jsx(Ge,{icon:Hn,label:o("deletePage"),disabled:d||l.pageCount<2,onClick:()=>void c("layout.pages.delete",{pages:[g]}),"data-testid":"layout-delete-page"})]})})]})}const Tj=[["left",VE],["center",_E],["right",UE],["justify",BE]];function kj(l,s){const u=l.map(c=>[c,c]);return s&&!l.includes(s)?[[s,s],...u]:u}const _t=l=>Math.round(l*100)/100;function Aj({info:l}){const{t:s,phrase:u}=Ne(),c=ml(),f=l.selection.length?Mj(l,l.selection[0]):null,o=f==null?void 0:f.item,d=l.editingText||(o==null?void 0:o.story)!=null;return!o&&!l.editingText?h.jsxs(_n,{title:u("Properties"),testId:"layout-properties",children:[h.jsx("p",{className:"layout-empty",children:s("nothingSelected")}),h.jsx("fieldset",{className:"layout-fieldset",disabled:c,children:h.jsx(jj,{info:l})})]}):h.jsx(_n,{title:u("Properties"),testId:"layout-properties",children:h.jsxs("fieldset",{className:"layout-fieldset",disabled:c,children:[o&&!l.editingText?h.jsx(Nj,{info:l,item:o}):null,o&&!l.editingText?h.jsx(Oj,{info:l,item:o}):null,d?h.jsx(Rj,{info:l}):null]})})}function jj({info:l}){var p,y,g;const{run:s,t:u}=Ne(),c=((y=(p=l.spreads[0])==null?void 0:p.pages[0])==null?void 0:y.background)??"",f=l.swatchColors.filter(v=>v.kind==="color"||v.kind==="tint"||v.kind==="paper"),o=((g=f.find(v=>v.name===c))==null?void 0:g.color)??"#ffffff",d=[["",u("noBackground")],...f.map(v=>[v.name,v.name])];return c&&!f.some(v=>v.name===c)&&d.push([c,c]),h.jsx("div",{className:"layout-stack","data-testid":"layout-page-background",children:h.jsxs("span",{className:"layout-color",children:[h.jsx(Da,{label:u("pageBackground"),value:c,choices:d,onChange:v=>void s("page.background",{color:v||null}),testId:"layout-background"}),h.jsx("input",{type:"color","aria-label":u("backgroundColor"),value:o,onChange:v=>void s("page.background",{color:v.target.value}),"data-testid":"layout-background-color"})]})})}function Nj({info:l,item:s}){const{run:u,t:c}=Ne(),f=Ln("transform.info",{ids:l.selection},l.selection.join(","));if(!f)return null;const o=d=>(p,y)=>{y&&Number.isFinite(p)&&u("transform.set",{[d]:p,ids:l.selection,...d==="rotation"?{}:{ref:0}})};return h.jsxs("div",{className:"layout-grid","data-testid":"layout-geometry","data-item":s.id,children:[h.jsx(xa,{label:"X",name:c("positionX"),value:_t(f.x),min:-1e5,max:1e5,step:1,unit:"pt",onChange:o("x"),testId:"layout-x"}),h.jsx(xa,{label:"Y",name:c("positionY"),value:_t(f.y),min:-1e5,max:1e5,step:1,unit:"pt",onChange:o("y"),testId:"layout-y"}),h.jsx(xa,{label:"W",name:c("width"),value:_t(f.width),min:.1,max:1e5,step:1,unit:"pt",onChange:o("width"),testId:"layout-w"}),h.jsx(xa,{label:"H",name:c("height"),value:_t(f.height),min:.1,max:1e5,step:1,unit:"pt",onChange:o("height"),testId:"layout-h"}),h.jsx(xa,{label:"∠",name:c("rotation"),value:_t(f.rotation),min:-360,max:360,step:1,unit:"°",onChange:o("rotation"),testId:"layout-rotation"}),h.jsxs("span",{className:"layout-buttons",children:[h.jsx("button",{type:"button",className:"kui-icon-button","aria-label":c("flipHorizontal"),title:c("flipHorizontal"),onClick:()=>void u("transform.flip",{axis:"horizontal",ids:l.selection}),"data-testid":"layout-flip-h",children:h.jsx(Vx,{size:16,"aria-hidden":"true"})}),h.jsx("button",{type:"button",className:"kui-icon-button","aria-label":c("flipVertical"),title:c("flipVertical"),onClick:()=>void u("transform.flip",{axis:"vertical",ids:l.selection}),"data-testid":"layout-flip-v",children:h.jsx(a0,{size:16,"aria-hidden":"true"})})]})]})}function Oj({info:l,item:s}){const{run:u,t:c,phrase:f}=Ne(),o=l.selection,d=l.swatchColors.filter(y=>y.kind!=="registration").map(y=>[y.name,y.name]),p=y=>d.some(([g])=>g===y)?d:[[y,y],...d];return h.jsxs("div",{className:"layout-stack","data-testid":"layout-appearance",children:[h.jsx(Da,{label:f("Fill"),value:s.fill,choices:p(s.fill),onChange:y=>void u("object.fill",{swatch:y,ids:o}),testId:"layout-fill"}),h.jsx(xa,{label:c("tint"),value:Math.round((s.fillTint??1)*100),min:0,max:100,step:1,unit:"%",track:!0,onChange:(y,g)=>g&&void u("object.fill",{swatch:s.fill,tint:y/100,ids:o}),testId:"layout-tint"}),h.jsx(Da,{label:f("Stroke"),value:s.stroke.swatch,choices:p(s.stroke.swatch),onChange:y=>void u("object.stroke",{swatch:y,ids:o}),testId:"layout-stroke"}),h.jsx(xa,{label:c("strokeWeight"),value:_t(s.stroke.weight),min:0,max:1e3,step:.5,unit:"pt",onChange:(y,g)=>g&&void u("object.stroke",{weight:y,ids:o}),testId:"layout-stroke-weight"}),h.jsx(xa,{label:f("Opacity"),value:Math.round((s.opacity??1)*100),min:0,max:100,step:1,unit:"%",track:!0,onChange:(y,g)=>g&&void u("object.opacity",{opacity:y/100,ids:o}),testId:"layout-opacity"}),h.jsx(xa,{label:c("cornerRadius"),value:_t(s.corner&&s.corner.shape!=="none"?s.corner.size:0),min:0,max:1e4,step:1,unit:"pt",onChange:(y,g)=>g&&void u("object.cornerOptions",{shape:y>0?"rounded":"none",size:y,ids:o}),testId:"layout-corner"})]})}function Rj({info:l}){var z,x,E;const{run:s,t:u,phrase:c,session:f}=Ne(),o=Ln("type.selectionAttrs",{},`${l.selection.join(",")}:${l.editingText}`),d=Ln("font.families",{},f.doc?"families":null),p=((z=o==null?void 0:o.chars)==null?void 0:z.fontFamily)??"",y=Ln("font.families",{family:p},p);if(!o)return null;const g=o.chars??{},v=(d??[]).map(T=>[T,T]);p&&!v.some(([T])=>T===p)&&v.unshift([p,p]);const b=T=>void s("type.char",{attrs:T}),M=((x=g.leading)==null?void 0:x.kind)==="points"?g.leading.value??0:0;return h.jsxs("div",{className:"layout-stack","data-testid":"layout-typography",children:[h.jsx(Da,{label:c("Font"),value:p,choices:v,onChange:T=>b({fontFamily:T}),testId:"layout-font"}),h.jsx(Da,{label:u("fontStyle"),value:g.fontStyle??"Regular",choices:kj((y==null?void 0:y.styles)??[],g.fontStyle),onChange:T=>b({fontStyle:T}),testId:"layout-font-style"}),h.jsxs("div",{className:"layout-grid",children:[h.jsx(xa,{label:u("fontSize"),value:_t(g.size??12),min:.1,max:1296,step:.5,unit:"pt",onChange:(T,C)=>C&&b({size:T}),testId:"layout-font-size"}),h.jsx(xa,{label:u("leading"),value:_t(M),min:0,max:5e3,step:.5,unit:M?"pt":u("auto"),onChange:(T,C)=>C&&b({leading:T>0?{kind:"points",value:T}:{kind:"auto"}}),testId:"layout-leading"}),h.jsx(xa,{label:u("tracking"),value:_t(g.tracking??0),min:-1e3,max:1e4,step:5,onChange:(T,C)=>C&&b({tracking:T}),testId:"layout-tracking"})]}),h.jsx(hg,{label:u("alignment"),value:((E=o.para)==null?void 0:E.align)??"left",segments:Tj.map(([T,C])=>({value:T,icon:C,label:u(`align.${T}`)})),onChange:T=>void s("type.para",{attrs:{align:T}}),testId:"layout-align"}),h.jsx(ua,{onClick:()=>void s("frame.fitText",l.editingText?{}:{ids:l.selection}),"data-testid":"layout-fit-text",children:c("Fit Text to Frame")}),h.jsx(Da,{label:c("Paragraph Style"),value:o.paragraphStyle??"",choices:l.paragraphStyles.map(T=>[T,T]),onChange:T=>void s("style.paragraph.apply",{name:T}),testId:"layout-paragraph-style-choice"}),h.jsx(Da,{label:c("Character Style"),value:o.characterStyle??"[None]",choices:l.characterStyles.map(T=>[T,T]),onChange:T=>void s("style.character.apply",{name:T}),testId:"layout-character-style-choice"})]})}const c5={pt:1,px:1,mm:72/25.4,in:72},ms=[{id:"letter",width:612,height:792,intent:"print",unit:"in"},{id:"a4",width:595.276,height:841.89,intent:"print",unit:"mm"},{id:"poster",width:1080,height:1440,intent:"web",unit:"px"},{id:"square",width:1080,height:1080,intent:"web",unit:"px"},{id:"story",width:1080,height:1920,intent:"mobile",unit:"px"},{id:"landscape",width:1920,height:1080,intent:"web",unit:"px"}];function Su(l,s){var c;const u=(f,o)=>Math.abs(f-o)<.5;return((c=ms.find(f=>u(f.width,l)&&u(f.height,s)))==null?void 0:c.id)??"custom"}function Lj({info:l,onClose:s}){var ue,we;const{run:u,t:c}=Ne(),f=(ue=l.spreads[0])==null?void 0:ue.pages[0],[o,d]=w.useState(l.settings.pageWidth),[p,y]=w.useState(l.settings.pageHeight),[g,v]=w.useState(()=>{var D;return((D=ms.find(L=>L.id===Su(l.settings.pageWidth,l.settings.pageHeight)))==null?void 0:D.unit)??"pt"}),[b,M]=w.useState(l.settings.intent||"print"),[z,x]=w.useState(l.settings.facingPages),[E,T]=w.useState(((we=f==null?void 0:f.margins)==null?void 0:we.top)??36),[C,N]=w.useState((f==null?void 0:f.columns)??1),[G,J]=w.useState(12),[$,le]=w.useState(0),Z=Su(o,p),ie=c5[g],se=D=>Math.round(D/ie*100)/100,ae=D=>{const L=ms.find(P=>P.id===D);L&&(d(L.width),y(L.height),v(L.unit),M(L.intent),L.intent!=="print"&&x(!1))},de=async()=>{await u("layout.documentSetup",{width:o,height:p,facingPages:z,intent:b,bleed:$}),await u("layout.marginsAndColumns",{margins:E,columns:C,gutter:G}),s()},q=(D,L,P,re,pe=.01)=>h.jsx(xa,{label:D,value:se(L),min:pe,max:1e5,step:g==="in"?.01:1,unit:g,onChange:(I,ye)=>ye&&P(I*ie),testId:re});return h.jsxs(Un,{title:c("documentSetup"),onClose:s,testId:"layout-setup-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:s,children:c("cancel")}),h.jsx(ua,{variant:"primary",onClick:()=>void de(),"data-testid":"layout-setup-ok",children:c("ok")})]}),children:[h.jsx("div",{className:"layout-presets",role:"radiogroup","aria-label":c("presets"),children:ms.map(D=>h.jsxs("button",{type:"button",role:"radio","aria-checked":Z===D.id,className:"layout-preset","data-active":Z===D.id,onClick:()=>ae(D.id),"data-testid":`layout-preset-${D.id}`,children:[h.jsx("span",{className:"layout-preset-shape",style:{aspectRatio:`${D.width} / ${D.height}`},"aria-hidden":"true"}),h.jsx("span",{children:c(`preset.${D.id}`)}),h.jsx("span",{className:"kui-muted",children:D.unit==="px"?`${D.width} × ${D.height} px`:c(`presetSize.${D.id}`)})]},D.id))}),h.jsxs("div",{className:"layout-grid",children:[h.jsx(Da,{label:c("units"),value:g,choices:Object.keys(c5).map(D=>[D,c(`unit.${D}`)]),onChange:v,testId:"layout-setup-unit"}),h.jsx(Da,{label:c("intent"),value:b,choices:["print","web","mobile"].map(D=>[D,c(`intent.${D}`)]),onChange:M,testId:"layout-setup-intent"}),q(c("width"),o,d,"layout-setup-width"),q(c("height"),p,y,"layout-setup-height"),q(c("margins"),E,T,"layout-setup-margins",0),q(c("bleed"),$,le,"layout-setup-bleed",0),h.jsx(xa,{label:c("columns"),value:C,min:1,max:216,step:1,onChange:(D,L)=>L&&N(Math.round(D)),testId:"layout-setup-columns"}),q(c("gutter"),G,J,"layout-setup-gutter",0)]}),h.jsx(H1,{label:c("facingPages"),checked:z,onChange:x,testId:"layout-setup-facing"}),h.jsx("p",{className:"kui-muted layout-note",children:c("presetCustom",{size:`${se(o)} × ${se(p)} ${g}`})})]})}const z1=ms.filter(l=>l.unit==="px"),zu=l=>Math.round(l*100)/100;function Dj({info:l,onShow:s}){const{run:u,t:c}=Ne(),f=ml(),[o,d]=w.useState(null),[p,y]=w.useState(!1),g=b=>l.spreads.find(M=>M.pages.some(z=>z.index===b.firstPage-1)),v=l.layouts.find(b=>b.name!=null&&b.name===o)??null;return h.jsxs(_n,{title:c("sizes"),actions:h.jsx(Ge,{icon:Dn,label:c("newSize"),disabled:f,onClick:()=>y(!0),"data-testid":"layout-new-size"}),testId:"layout-sizes",children:[h.jsx("div",{"data-testid":"layout-size-list","data-count":l.layouts.length,children:l.layouts.map(b=>{const M=b.name??c("originalSize");return h.jsxs("button",{type:"button",className:"layout-list-item layout-size-row","data-active":b.name!=null&&b.name===o,onClick:()=>{d(b.name);const z=g(b);z&&s(z)},"data-testid":`layout-size-${b.name??"original"}`,children:[h.jsx("span",{className:"layout-row-text",children:M}),h.jsx("span",{className:"kui-muted layout-count",children:c("sizeOf",{width:zu(b.width),height:zu(b.height)})})]},b.name??"")})}),h.jsx(hi,{end:h.jsx(Ge,{icon:Hn,label:c("deleteSize"),disabled:f||!v,onClick:()=>(v==null?void 0:v.name)&&void u("layout.deleteAlternate",{name:v.name}).then(()=>d(null)),"data-testid":"layout-delete-size"})}),p?h.jsx(Hj,{info:l,onClose:()=>y(!1),onMade:d}):null]})}function Hj({info:l,onClose:s,onMade:u}){const{run:c,t:f}=Ne(),o=new Set(l.layouts.map(G=>G.name).filter(G=>G!=null)),d=l.layouts[0],p=z1.find(G=>!d||Su(d.width,d.height)!==G.id)??z1[0],[y,g]=w.useState(p.width),[v,b]=w.useState(p.height),M=Su(y,v),z=G=>{const J=G==="custom"?f("sizeOf",{width:zu(y),height:zu(v)}):f(`preset.${G}`);let $=J;for(let le=2;o.has($);le+=1)$=`${J} ${le}`;return $},[x,E]=w.useState(null),T=x??z(M),C=T.trim()!==""&&!o.has(T.trim()),N=async()=>{C&&(await c("layout.createAlternate",{name:T.trim(),width:y,height:v}),u(T.trim()),s())};return h.jsxs(Un,{title:f("newSize"),onClose:s,testId:"layout-size-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:s,children:f("cancel")}),h.jsx(ua,{variant:"primary",disabled:!C,onClick:()=>void N(),"data-testid":"layout-size-ok",children:f("ok")})]}),children:[h.jsx("div",{className:"layout-presets",role:"radiogroup","aria-label":f("presets"),children:z1.map(G=>h.jsxs("button",{type:"button",role:"radio","aria-checked":M===G.id,className:"layout-preset","data-active":M===G.id,onClick:()=>{g(G.width),b(G.height)},"data-testid":`layout-size-preset-${G.id}`,children:[h.jsx("span",{className:"layout-preset-shape",style:{aspectRatio:`${G.width} / ${G.height}`},"aria-hidden":"true"}),h.jsx("span",{children:f(`preset.${G.id}`)}),h.jsx("span",{className:"kui-muted",children:`${G.width} × ${G.height} px`})]},G.id))}),h.jsxs("div",{className:"layout-grid",children:[h.jsx(xa,{label:f("width"),value:y,min:1,max:15552,step:1,unit:"px",onChange:(G,J)=>J&&g(G),testId:"layout-size-width"}),h.jsx(xa,{label:f("height"),value:v,min:1,max:15552,step:1,unit:"px",onChange:(G,J)=>J&&b(G),testId:"layout-size-height"})]}),h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:f("sizeName")}),h.jsx("input",{className:"kui-field",value:T,onChange:G=>E(G.target.value),"data-testid":"layout-size-name"})]}),o.has(T.trim())?h.jsx("p",{className:"kui-muted layout-note",children:f("sizeNameTaken")}):h.jsx("p",{className:"kui-muted layout-note",children:f("sizeNote")})]})}const Q1=new Set(["[No Paragraph Style]","[Basic Paragraph]","[None]"]);function o5({info:l,kind:s}){const{run:u,phrase:c,t:f}=Ne(),o=ml(),d=s==="paragraph"?l.paragraphStyles:l.characterStyles,p=Ln("type.selectionAttrs",{},`${l.selection.join(",")}:${l.editingText}`),y=s==="paragraph"?p==null?void 0:p.paragraphStyle:p==null?void 0:p.characterStyle,[g,v]=w.useState(null),[b,M]=w.useState(null),z=s==="paragraph"?"layout-paragraph-style":"layout-character-style",x=C=>{v(C),o||u(s==="paragraph"?"style.paragraph.apply":"style.character.apply",{name:C})},E=async()=>{const C=f(s==="paragraph"?"newParagraphStyleName":"newCharacterStyleName");let N=C;for(let G=2;d.includes(N);G+=1)N=`${C} ${G}`;if(s==="paragraph")await u("style.paragraph.create",{name:N,fromSelection:l.editingText||l.selection.length>0});else{const G=(p==null?void 0:p.chars)??{},J=Object.fromEntries(["fontFamily","fontStyle","size","fill","tracking"].filter($=>G[$]!=null).map($=>[$,G[$]]));await u("style.character.create",{name:N,chars:J})}v(N)},T=g&&d.includes(g)?g:null;return h.jsxs(_n,{title:c(s==="paragraph"?"Paragraph Styles":"Character Styles"),defaultOpen:!1,testId:`${z}s`,children:[d.map(C=>h.jsx("button",{type:"button",className:"layout-list-item","data-active":C===T,"data-current":C===y,onClick:()=>x(C),onDoubleClick:()=>M(C),"data-testid":`${z}-${C}`,children:C},C)),h.jsx(hi,{end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:Dn,label:f(s==="paragraph"?"newParagraphStyle":"newCharacterStyle"),disabled:o,onClick:()=>void E(),"data-testid":`${z}-new`}),h.jsx(Ge,{icon:Ms,label:f("editStyle"),disabled:o||!T,onClick:()=>T&&M(T),"data-testid":`${z}-edit`}),h.jsx(Ge,{icon:Hn,label:f("deleteStyle"),disabled:!T||Q1.has(T),onClick:()=>T&&void u(s==="paragraph"?"style.paragraph.delete":"style.character.delete",{name:T}).then(()=>v(null)),"data-testid":`${z}-delete`})]})}),b?h.jsx(Uj,{info:l,kind:s,name:b,onClose:()=>M(null)}):null]})}const _j=["","left","center","right","justify"];function Uj({info:l,kind:s,name:u,onClose:c}){const{run:f,t:o,phrase:d,session:p}=Ne(),y=Ln("font.families",{},p.doc?"families":null)??[],[g,v]=w.useState(u),[b,M]=w.useState(""),[z,x]=w.useState(""),[E,T]=w.useState(""),[C,N]=w.useState(""),[G,J]=w.useState(""),[$,le]=w.useState(""),Z=ae=>ae.trim()===""||!Number.isFinite(Number(ae))?void 0:Number(ae),ie=async()=>{const ae={};b&&(ae.fontFamily=b),Z(z)!=null&&(ae.size=Z(z)),Z(E)!=null&&(ae.leading={kind:"points",value:Z(E)}),Z(C)!=null&&(ae.tracking=Z(C)),G&&(ae.fill=G);const de={name:u,chars:ae};g.trim()&&g.trim()!==u&&!Q1.has(u)&&(de.rename=g.trim()),s==="paragraph"&&$&&(de.para={align:$}),await f(s==="paragraph"?"style.paragraph.edit":"style.character.edit",de),c()},se=(ae,de,q,ue)=>h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:ae}),h.jsx("input",{className:"kui-field",inputMode:"decimal",value:de,placeholder:o("unchanged"),onChange:we=>q(we.target.value),"data-testid":ue})]});return h.jsxs(Un,{title:o("styleOptions",{name:u}),onClose:c,testId:"layout-style-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:c,children:o("cancel")}),h.jsx(ua,{variant:"primary",onClick:()=>void ie(),"data-testid":"layout-style-ok",children:o("ok")})]}),children:[h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:o("styleName")}),h.jsx("input",{className:"kui-field",value:g,disabled:Q1.has(u),onChange:ae=>v(ae.target.value),"data-testid":"layout-style-name"})]}),h.jsx(Da,{label:d("Font"),value:b,choices:[["",o("unchanged")],...y.map(ae=>[ae,ae])],onChange:M,testId:"layout-style-font"}),se(o("fontSize"),z,x,"layout-style-size"),se(o("leading"),E,T,"layout-style-leading"),se(o("tracking"),C,N,"layout-style-tracking"),h.jsx(Da,{label:d("Fill"),value:G,choices:[["",o("unchanged")],...l.swatches.map(ae=>[ae,ae])],onChange:J,testId:"layout-style-fill"}),s==="paragraph"?h.jsx(Da,{label:o("alignment"),value:$,choices:_j.map(ae=>[ae,o(ae?`align.${ae}`:"unchanged")]),onChange:le,testId:"layout-style-align"}):null]})}function Bj({info:l}){const{run:s,phrase:u,t:c}=Ne(),f=ml(),[o,d]=w.useState("fill"),[p,y]=w.useState(100),[g,v]=w.useState(null),[b,M]=w.useState(!1),z=E=>{v(E.name),!(f||!l.selection.length&&!l.editingText)&&(l.editingText?s("type.char",{attrs:o==="fill"?{fill:E.name}:{stroke:E.name}}):o==="fill"?s("object.fill",{swatch:E.name,tint:p/100,ids:l.selection}):s("object.stroke",{swatch:E.name,tint:p/100,ids:l.selection}))},x=l.swatchColors.find(E=>E.name===g&&!E.locked&&E.kind!=="none"&&E.kind!=="paper"&&E.kind!=="registration");return h.jsxs(_n,{title:u("Swatches"),defaultOpen:!1,testId:"layout-swatches",children:[h.jsxs("div",{className:"layout-bar",children:[h.jsx(hg,{label:c("swatchTarget"),value:o,segments:[{value:"fill",icon:Ss,label:u("Fill")},{value:"stroke",icon:R1,label:u("Stroke")}],onChange:d,testId:"layout-swatch-target"}),h.jsx(xa,{label:c("tint"),value:p,min:0,max:100,step:1,unit:"%",width:64,onChange:E=>y(E),testId:"layout-swatch-tint"})]}),l.swatchColors.map(E=>h.jsxs("button",{type:"button",className:"layout-list-item layout-swatch-row","data-active":E.name===g,onClick:()=>z(E),"data-testid":`layout-swatch-${E.name}`,children:[h.jsx("span",{className:"layout-chip","data-kind":E.kind,style:E.color?{background:E.color}:void 0,"aria-hidden":"true"}),h.jsx("span",{className:"layout-row-text",children:E.name})]},E.name)),h.jsx(hi,{end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:Dn,label:c("newSwatch"),disabled:f,onClick:()=>M(!0),"data-testid":"layout-new-swatch"}),h.jsx(Ge,{icon:Hn,label:c("deleteSwatch"),disabled:f||!x,onClick:()=>x&&void s("swatch.delete",{name:x.name}).then(()=>v(null)),"data-testid":"layout-delete-swatch"})]})}),b?h.jsx(Vj,{onClose:()=>M(!1)}):null]})}function Vj({onClose:l}){const{run:s,t:u}=Ne(),[c,f]=w.useState(""),[o,d]=w.useState("#5645d4"),p=/^#[0-9a-f]{6}$/i.test(o),y=async()=>{p&&(await s("swatch.create",c.trim()?{name:c.trim(),color:o}:{color:o}),l())};return h.jsxs(Un,{title:u("newSwatch"),onClose:l,testId:"layout-new-swatch-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:l,children:u("cancel")}),h.jsx(ua,{variant:"primary",disabled:!p,onClick:()=>void y(),"data-testid":"layout-new-swatch-ok",children:u("ok")})]}),children:[h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:u("swatchName")}),h.jsx("input",{className:"kui-field",value:c,placeholder:u("swatchNameHint"),onChange:g=>f(g.target.value),"data-testid":"layout-new-swatch-name"})]}),h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:u("swatchColor")}),h.jsxs("span",{className:"layout-color",children:[h.jsx("input",{type:"color",value:p?o:"#000000",onChange:g=>d(g.target.value),"aria-label":u("swatchColor")}),h.jsx("input",{className:"kui-field",value:o,onChange:g=>d(g.target.value.trim()),"data-testid":"layout-new-swatch-color"})]})]})]})}function qj({info:l,spread:s,onShow:u,onSetup:c}){return h.jsx("aside",{className:"kui-panel layout-side","data-side":"right","data-testid":"layout-side",children:h.jsxs("div",{className:"kui-panel-body",children:[h.jsx(Aj,{info:l}),h.jsx(Ej,{info:l,onShow:u,onSetup:c}),h.jsx(Dj,{info:l,onShow:u}),h.jsx(xj,{info:l,spread:s}),h.jsx(Bj,{info:l}),h.jsx(o5,{info:l,kind:"paragraph"}),h.jsx(o5,{info:l,kind:"character"}),h.jsx(Sj,{info:l})]})})}const fl=18,x1=[1,2,5,10,20,25,50,100,200,250,500,1e3,2e3,5e3,1e4],Gj=56;function f5(l){return x1.find(s=>s*l>=Gj)??x1[x1.length-1]}function Ig(l,s){const u=s.x+s.width/2/s.zoom,c=s.y+s.height/2/s.zoom,f=$g(l,u,c);if(!f)return null;const o=u-f.area.x0+f.left,d=f.pages.find(p=>o>=p.bounds[0]&&o<=p.bounds[2])??f.pages[0];return{x:f.area.x0+(d?d.bounds[0]:f.left)-f.left,y:f.area.y0,spread:f}}function C1(l,s){const[u,c]=w.useState(s);return w.useEffect(()=>{const f=getComputedStyle(document.documentElement).getPropertyValue(l).trim();f&&c(f)},[l]),u}function d5({axis:l,info:s,view:u,onGuide:c}){const f=w.useRef(null),[o,d]=w.useState({width:0,height:0}),p=C1("--kit-text-muted","#6b6b76"),y=C1("--kit-border","#d9d9e0"),g=C1("--kit-surface","#ffffff"),v=u?Ig(s,u):null,b=u&&v?l==="x"?(v.x-u.x)*u.zoom:(v.y-u.y)*u.zoom:0;w.useEffect(()=>{const z=f.current;if(!z||typeof ResizeObserver>"u")return;const x=new ResizeObserver(([E])=>d({width:E.contentRect.width,height:E.contentRect.height}));return x.observe(z),()=>x.disconnect()},[]),w.useEffect(()=>{const z=f.current,x=z==null?void 0:z.getContext("2d");if(!z||!x||!u||!o.width||!o.height)return;const E=window.devicePixelRatio||1;z.width=Math.round(o.width*E),z.height=Math.round(o.height*E),x.setTransform(E,0,0,E,0,0),x.fillStyle=g,x.fillRect(0,0,o.width,o.height),x.strokeStyle=y,x.fillStyle=p,x.lineWidth=1,x.font="9px system-ui, sans-serif",x.beginPath(),l==="x"?(x.moveTo(0,o.height-.5),x.lineTo(o.width,o.height-.5)):(x.moveTo(o.width-.5,0),x.lineTo(o.width-.5,o.height));const T=l==="x"?o.width:o.height,C=f5(u.zoom),N=C/5,G=Math.floor(-b/u.zoom/N)*N;for(let J=G;J*u.zoom+b<=T;J+=N){const $=Math.round(J*u.zoom+b)+.5,le=Math.abs(J/C-Math.round(J/C))<1e-6,Z=le?fl:fl*.3;l==="x"?(x.moveTo($,fl-Z),x.lineTo($,fl),le&&x.fillText(String(Math.round(J)),$+2,9)):(x.moveTo(fl-Z,$),x.lineTo(fl,$),le&&(x.save(),x.translate(9,$+2),x.rotate(-Math.PI/2),x.textAlign="right",x.fillText(String(Math.round(J)),0,0),x.restore()))}x.stroke()},[b,l,y,o,g,p,u]);const M=z=>{if(z.button!==0||!u)return;const x=z.currentTarget.getBoundingClientRect(),E=T=>{window.removeEventListener("pointerup",E);const C=l==="x"?x.left:x.right,N=l==="x"?x.bottom:x.top,G=(T.clientX-C)/u.zoom,J=(T.clientY-N)/u.zoom;if(l==="x"&&J<=0||l==="y"&&G<=0)return;const $=u.x+G,le=u.y+J,Z=$g(s,$,le);Z&&(l==="x"?c("horizontal",le-Z.area.y0,Z.index):c("vertical",$-Z.area.x0+Z.left,Z.index))};window.addEventListener("pointerup",E)};return h.jsx("canvas",{ref:f,className:"layout-ruler","data-axis":l,"data-origin":Math.round(b*100)/100,"data-zoom":u==null?void 0:u.zoom,"data-step":u?f5(u.zoom):void 0,onPointerDown:M,"data-testid":`layout-ruler-${l}`})}const Zg=["png","jpeg","pdf","idml","epub","html"],Fg={png:"png",jpeg:"jpg",pdf:"pdf",idml:"idml",epub:"epub",html:"html"};function Yj(l,s){const u={format:Fg[l]};return l==="pdf"&&Object.assign(u,s.pages?{pages:s.pages}:{},{bleed:s.bleed}),{command:"file.exportBytes",params:u}}function J1(l){return Uint8Array.from(atob(l),s=>s.charCodeAt(0))}function $j(l){return l?typeof l.data=="string"?J1(l.data):typeof l.base64=="string"?J1(l.base64):typeof l.text=="string"?new TextEncoder().encode(l.text):null:null}function Xj(l){return l.replace(/\.[^.]+$/,"").trim()||"Untitled"}function Kj(l){return l.includes("/")?l.slice(0,l.lastIndexOf("/")+1):""}function h5(l,s,u=""){return`${Kj(l.path)}${Xj(l.name)}${u}.${Fg[s]}`}async function Ij(l,s){const u=[];for(const c of l){const f=await s(c.path,c.bytes);if(typeof f!="string"||!f)throw new Error(`the host did not write ${c.path}`);u.push(f)}return u}const Qg={format:"png",range:"all",pages:"",ppi:72,transparent:!1,quality:90,bleed:!1};function Zj(l){if(!l||typeof l!="object")return;const s={...Qg,...l};if(!(!Zg.includes(s.format)||!["all","current","range","sizes"].includes(s.range))&&!(!Number.isFinite(s.ppi)||s.ppi<1||s.ppi>2400||!Number.isFinite(s.quality)))return s}const Fj=l=>l.replace(/[\\/:*?"<>|]+/g,"-").trim()||"size";function Qj({info:l,page:s,onClose:u}){const{query:c,host:f,t:o}=Ne(),d=`export:${f.init.document.path}`,[p,y]=db("kit.layout",d,{initial:Qg,validate:Zj}),[g,v]=w.useState(p),[b,M]=w.useState(!1),z=$=>v(le=>({...le,...$})),x=g.format==="png"||g.format==="jpeg",E=x||g.format==="pdf",T=g.range==="sizes"&&l.layouts.length>1&&x,C=g.range==="sizes"&&!T?"all":g.range,N=C==="all"||T?void 0:C==="current"?String(s+1):g.pages.trim()||void 0,G={name:f.init.document.name||"Untitled",path:f.init.document.path},J=async()=>{M(!0),y(g);try{const $=[];if(x){const Z=await c("file.exportImage",{format:g.format,...N?{pages:N}:{},...T?{sizes:!0}:{},ppi:g.ppi,background:g.format==="png"&&g.transparent?"transparent":"paper",quality:g.quality,bleed:g.bleed});if(!Z)throw new Error(o("exportFailed"));const ie=Z.files.length>1,se=ae=>Z.files.filter(de=>de.layout===ae).length;for(const ae of Z.files){const de=l.layouts.length>1&&ae.layout!=null,q=de?se(ae.layout)>1:ie&&(l.layouts.length<2||se(null)>1),ue=`${de?`-${Fj(ae.layout??"")}`:""}${q?`-${ae.page}`:""}`;$.push({path:h5(G,g.format,ue),bytes:J1(ae.base64)})}}else{const Z=Yj(g.format,{pages:N,bleed:g.bleed}),ie=$j(await c(Z.command,Z.params));if(!ie)throw new Error(o("exportFailed"));$.push({path:h5(G,g.format),bytes:ie})}const le=await Ij($,(Z,ie)=>f.exportFile(Z,ie));ui("success",o("exported",{count:le.length}),le.map(Z=>Z.split("/").pop()).join(", ")),u()}catch($){ui("error",o("exportFailed"),$ instanceof Error?$.message:String($))}finally{M(!1)}};return h.jsx(Un,{title:o("export"),onClose:u,testId:"layout-export-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:u,children:o("cancel")}),h.jsx(ua,{variant:"primary",disabled:b,onClick:()=>void J(),"data-testid":"layout-export-ok",children:o("exportAction")})]}),children:h.jsxs("div",{className:"layout-dialog-stack",children:[h.jsx(Da,{label:o("format"),value:g.format,choices:Zg.map($=>[$,o(`format.${$}`)]),onChange:$=>z({format:$}),testId:"layout-export-format"}),E?h.jsxs(h.Fragment,{children:[h.jsx(Da,{label:o("pages"),value:C,choices:[["all",o("allPages",{count:l.pageCount})],...x&&l.layouts.length>1?[["sizes",o("allSizes",{count:l.layouts.length})]]:[],["current",o("currentPage",{page:s+1})],["range",o("pageRange")]],onChange:$=>z({range:$}),testId:"layout-export-range"}),C==="range"?h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:o("pageRange")}),h.jsx("input",{className:"kui-field",value:g.pages,placeholder:"1-3, 5",onChange:$=>z({pages:$.target.value}),"data-testid":"layout-export-pages"})]}):null,h.jsx(H1,{label:o("includeBleed"),checked:g.bleed,onChange:$=>z({bleed:$}),testId:"layout-export-bleed"})]}):null,x?h.jsxs(h.Fragment,{children:[h.jsx(Da,{label:o("resolution"),value:String(g.ppi),choices:[72,144,216,300].map($=>[String($),o("scale",{scale:$/72,ppi:$})]),onChange:$=>z({ppi:Number($)}),testId:"layout-export-ppi"}),g.format==="png"?h.jsx(H1,{label:o("transparentBackground"),checked:g.transparent,onChange:$=>z({transparent:$}),testId:"layout-export-transparent"}):null,g.format==="jpeg"?h.jsx(xa,{label:o("quality"),value:g.quality,min:1,max:100,step:1,track:!0,onChange:($,le)=>le&&z({quality:$}),testId:"layout-export-quality"}):null]}):null]})})}const Jj=l=>new URL(`./templates/${l}.png`,document.baseURI).href;function Pj({onClose:l}){const{run:s,t:u}=Ne(),c=Ln("template.list",{},"templates")??[],f=async o=>{await s("document.applyTemplate",{template:o}),l()};return h.jsxs(Un,{title:u("templates"),onClose:l,testId:"layout-templates-dialog",actions:h.jsx(ua,{onClick:l,children:u("cancel")}),children:[h.jsx("div",{className:"layout-templates",role:"list",children:c.map(o=>h.jsxs("button",{type:"button",role:"listitem",className:"layout-template",onClick:()=>void f(o.id),"data-testid":`layout-template-${o.id}`,children:[h.jsx("img",{className:"layout-template-preview",src:Jj(o.id),alt:"",style:{aspectRatio:`${o.width} / ${o.height}`}}),h.jsx("span",{children:u(`template.${o.id}`)}),h.jsx("span",{className:"kui-muted",children:`${o.width} × ${o.height} px`})]},o.id))}),h.jsx("p",{className:"kui-muted layout-note",children:u("templatesNote")})]})}const Wj={hand:Dt,zoom:gk},eN=new Set(Kg),aN=["file.new","book.new","library.new","file.open","file.close","file.save","file.saveAs","file.revert"],tN=["document.applyTemplate","layout.documentSetup","file.exportPdf","file.exportEpub","file.exportFixedEpub","file.exportHtml"],nN=["View","Window","Help"];function lN({host:l,phrase:s}){var Z,ie;const u=w.useMemo(()=>Lg(Yg,l.init.locale),[l]),c=w.useMemo(hj,[]),f=bA(l,c,gj),o=Gk(f,l,u,"layout",s),{doc:d,change:p,state:y}=f,g=lj(f.tool,d!=null,p,{initial:"selection",hostTools:Wj,hidden:eN}),v=w.useRef(null);fj(d,v);const b=w.useRef(null),[M,z]=w.useState(null),[x,E]=w.useState(null),T=(M==null?void 0:M.zoom)??1,C=y&&M?Ig(y,M):null,N=(C==null?void 0:C.spread)??(y==null?void 0:y.spreads[0])??null,G=C?((Z=C.spread.pages.find(se=>C.spread.area.x0+se.bounds[0]-C.spread.left===C.x))==null?void 0:Z.index)??0:0,{commands:J}=o,$=(se,ae,de)=>{l.readOnly||o.run("guide.add",{orientation:se,position:ae,spread:de})},le=w.useMemo(()=>[{id:"home",label:u("homeTab"),ribbon:h.jsx(zj,{onDialog:E})},...DA(J,{order:bj,exclude:[...aN,...tN],phrase:s,view:nN,primary:wj,before:{File:[{label:u("templatesMenu"),onSelect:()=>E("templates"),testId:"layout-menu-templates",primary:!0},{label:u("documentSetupMenu"),onSelect:()=>E("setup"),testId:"layout-menu-document-setup",primary:!0},{label:u("exportMenu"),onSelect:()=>E("export"),testId:"layout-menu-export",primary:!0}]}})],[J,s,u]);return h.jsx(Yk,{editor:o,tools:g,children:h.jsxs(JA,{tabs:le,defaultTab:"home",canvas:v,zoom:T,onKeyDown:se=>se.key!=="Escape"||se.metaKey||se.ctrlKey||se.altKey||se.shiftKey||!(y!=null&&y.selected)?!1:(o.run("selection.set",{ids:[]}),!0),status:h.jsxs(h.Fragment,{children:[h.jsx("span",{"data-testid":"layout-status",children:g.status?s(g.status):y?u(y.pageCount===1?"summaryOne":"summary",{pages:y.pageCount}):""}),y!=null&&y.selected?h.jsx("span",{children:u("selectedCount",{count:y.selected})}):null]}),rail:h.jsx(uA,{hidden:Kg}),panels:y?h.jsx(qj,{info:y,spread:N,onShow:se=>{var ae;return(ae=v.current)==null?void 0:ae.show(se.area)},onSetup:()=>E("setup")}):null,children:[h.jsx("div",{className:"kui-row","data-testid":"layout-workspace","data-view":M?`${M.zoom} ${M.x} ${M.y}`:void 0,children:h.jsx(iN,{rulers:h.jsxs(h.Fragment,{children:[h.jsx("span",{className:"layout-ruler-corner","aria-hidden":"true"}),y?h.jsx(d5,{axis:"x",info:y,view:M,onGuide:$}):h.jsx("span",{}),y?h.jsx(d5,{axis:"y",info:y,view:M,onGuide:$}):h.jsx("span",{})]}),children:h.jsx(Kk,{canvas:v,viewMemory:b,initialArea:((ie=y==null?void 0:y.spreads[0])==null?void 0:ie.area)??null,framed:!1,onView:z})})}),y&&x==="setup"?h.jsx(Lj,{info:y,onClose:()=>E(null)}):null,y&&x==="export"?h.jsx(Qj,{info:y,page:G,onClose:()=>E(null)}):null,y&&x==="templates"?h.jsx(Pj,{onClose:()=>E(null)}):null]})})}function iN({rulers:l,children:s}){const u=VA()==="focus",c=u?"minmax(0, 1fr)":`${fl}px minmax(0, 1fr)`;return h.jsxs("div",{className:"layout-canvas-frame",style:{gridTemplateColumns:c,gridTemplateRows:c},children:[u?null:l,s]})}const sN={display:"line",brand:{light:"#d32f8d",dark:"#f57bbd"}},m5={ui:sN},Jg=fb.createRoot(document.getElementById("root")),rN=window.setTimeout(()=>{const l=Lg(Yg,navigator.language);Jg.render(h.jsx("div",{className:"kui-alone",children:l("noHost")}))},3e3);BT({id:"kit.layout",version:"0.1.3",capabilities:["ai","replica"],brand:m5.ui.brand,display:m5.ui.display}).then(async l=>{window.clearTimeout(rN);const s=oj(await cj({},l.init.locale),pj,l.init.locale);Jg.render(h.jsx(lN,{host:l,phrase:s}))});
52
+ `)){if(!u.trim()||u.startsWith("#"))continue;const[,c,f]=u.split(" ");c&&f&&s.set(wu(c),wu(f.replace(/\r$/,"")))}return s}function uj(l){const s=new Map;for(const u of l.matchAll(/"((?:[^"\\]|\\.)*)"\s*=>\s*"((?:[^"\\]|\\.)*)"/g))s.set(wu(u[1]),wu(u[2]));return s}function qg(l){const s=l.toLowerCase(),[u,c]=s.split("-"),f=[s];return u==="zh"&&f.push(["tw","hk","mo","hant"].includes(c??"")?"zh-hant":"zh-hans"),u==="sr"&&s.includes("latn")&&f.push("sr-latn"),f.push(u),f}async function cj(l,s){const u=new Map(Object.entries(l).map(([y,g])=>[y.split("/").pop().replace(/\.(tsv|rs)$/,"").toLowerCase(),{path:y,load:g}])),c=qg(s).find(y=>u.has(y));if(!c||s.toLowerCase().startsWith("en"))return y=>y;const{path:f,load:o}=u.get(c),d=String(await o()),p=f.endsWith(".rs")?uj(d):rj(d);return y=>p.get(y)??y}function oj(l,s,u){var o;const c=qg(u).concat(u).find(d=>Object.keys(s).some(p=>p.toLowerCase()===d)),f=c?(o=Object.entries(s).find(([d])=>d.toLowerCase()===c))==null?void 0:o[1]:void 0;return!f||u.toLowerCase().startsWith("en")?l:d=>f[d]??l(d)}sk({"anchored.release":nu,"conveyor.collect":H4,"index.generate":j1,"layout.detachAll":nu,"library.json":Ix,"math.svg":h0,"object.attributes":tu,"object.bevel":kC,"object.content":k1,"object.directionalFeather":dm,"object.dropShadow":di,"object.feather":dm,"object.fit":u0,"object.innerGlow":RE,"object.innerShadow":xE,"object.label":Q4,"object.outerGlow":OE,"object.pathfinder":EE,"object.satin":W4,"object.setFlags":T4,"script.run":CE,"select.container":ps,"select.content":k1,"select.firstAbove":t0,"select.lastBelow":I4,"states.release":nu,"transform.shear":tE,"xml.loadDtd":wC,"xml.structure":uC,"xref.formats":oi,"xref.setFormat":oi});const i5=/^#[0-9a-f]{6}$/i;function Gg(l=document.documentElement){const s=getComputedStyle(l).getPropertyValue("--kit-canvas").trim();if(i5.test(s))return s.toLowerCase();if(!s||typeof CSS>"u"||!CSS.supports("color",s))return null;const u=document.createElement("canvas").getContext("2d");if(!u)return null;u.fillStyle=s;const c=String(u.fillStyle);return i5.test(c)?c.toLowerCase():null}function fj(l,s){w.useEffect(()=>{if(!l)return;let u=!0,c=null;const f=()=>{const d=Gg();!d||d===c||(c=d,l.invoke("setBackdrop",d).then(()=>{var p;return u?(p=s.current)==null?void 0:p.retryRender():void 0}).catch(()=>{}))};f();const o=typeof MutationObserver>"u"?null:new MutationObserver(f);return o==null||o.observe(document.documentElement,{attributes:!0,attributeFilter:["style","data-color-scheme","class"]}),()=>{u=!1,o==null||o.disconnect()}},[l,s])}const dj=["DroidSansFallbackFull.ttf","Inter-Variable.ttf","Lora-Variable.ttf","JetBrainsMono-Variable.ttf","BricolageGrotesque-Variable.ttf"];function hj(){const l=Gg();return{kitId:"kit.layout",base:new URL("./engine/",document.baseURI).href,module:"kition_layout_kit",documentClass:"LayoutDocument",setup:l?[{method:"setBackdrop",args:[l]}]:[],fonts:dj.map(s=>new URL(`./fonts/${s}`,document.baseURI).href)}}const mj={summary:"{pages} pages",summaryOne:"{pages} page",selectedCount:"{count} selected",addPage:"Add page",newLayer:"New layer",hideLayer:"Hide layer",showLayer:"Show layer",lockLayer:"Lock layer",unlockLayer:"Unlock layer",nothingSelected:"Select an object or text to see its properties.",positionX:"X position",positionY:"Y position",width:"Width",height:"Height",rotation:"Rotation",flipHorizontal:"Flip horizontal",flipVertical:"Flip vertical",tint:"Tint",strokeWeight:"Weight",cornerRadius:"Corner radius",fontSize:"Size",fontStyle:"Style",leading:"Leading",auto:"auto",tracking:"Tracking",alignment:"Alignment","align.left":"Align left","align.center":"Align center","align.right":"Align right","align.justify":"Justify",parentItems:"{count} objects",noParent:"[None]",newParent:"New parent",pageParent:"Parent of the page",movePageUp:"Move page up",movePageDown:"Move page down",duplicateSpread:"Duplicate spread",deletePage:"Delete page",collapse:"Collapse",expand:"Expand",renameLayer:"Layer name",renameObject:"Object name",hideObject:"Hide object",showObject:"Show object",lockObject:"Lock object",unlockObject:"Unlock object",layerUp:"Move layer up",layerDown:"Move layer down",swatchTarget:"Apply to",newSwatch:"New swatch",deleteSwatch:"Delete swatch",swatchName:"Name",swatchNameHint:"Named after its value",swatchColor:"Color",cancel:"Cancel",ok:"OK",newParagraphStyle:"New paragraph style from the selection",newCharacterStyle:"New character style from the selection",newParagraphStyleName:"Paragraph Style",newCharacterStyleName:"Character Style",editStyle:"Edit style",deleteStyle:"Delete style",styleOptions:"Style options: {name}",styleName:"Style name",unchanged:"As it is",noLinks:"No placed graphics.",goToLink:"Select its frames",relink:"Relink",placeImage:"Place image",placePurpose:"Place an image",relinkPurpose:"Relink {name}",ppi:"{ppi} ppi","link.ok":"Linked","link.modified":"Modified","link.missing":"Missing","link.embedded":"Embedded",documentSetup:"Document setup",presets:"Sizes","preset.letter":"Letter","preset.a4":"A4","preset.poster":"Poster","preset.square":"Square","preset.story":"Story","preset.landscape":"Landscape","presetSize.letter":"8.5 × 11 in","presetSize.a4":"210 × 297 mm","presetSize.poster":"1080 × 1440 px","presetSize.square":"1080 × 1080 px","presetSize.story":"1080 × 1920 px","presetSize.landscape":"1920 × 1080 px",presetCustom:"Page size: {size}",units:"Units","unit.pt":"Points","unit.px":"Pixels","unit.mm":"Millimeters","unit.in":"Inches",intent:"Intent","intent.print":"Print","intent.web":"Web","intent.mobile":"Mobile",margins:"Margins",bleed:"Bleed",columns:"Columns",gutter:"Gutter",facingPages:"Facing pages",export:"Export",exportAction:"Export",exported:"Exported {count} files",exportFailed:"Could not export",format:"Format","format.png":"PNG image","format.jpeg":"JPEG image","format.pdf":"PDF","format.idml":"InDesign Markup (IDML)","format.epub":"EPUB","format.html":"HTML",pages:"Pages",allPages:"All pages ({count})",currentPage:"Page {page}",pageRange:"Range",includeBleed:"Include bleed",resolution:"Resolution",scale:"{scale}× ({ppi} ppi)",transparentBackground:"Transparent background",quality:"Quality",exportMenu:"Export…",documentSetupMenu:"Document Setup…",sizes:"Sizes",newSize:"New size",deleteSize:"Delete size",originalSize:"Original",sizeOf:"{width} × {height}",sizeName:"Name",sizeNameTaken:"A size with this name exists.",sizeNote:"A copy of the original at this size; objects follow their liquid rules.",allSizes:"Every size ({count})",pageBackground:"Page background",backgroundColor:"Background color",noBackground:"None (transparent)",templates:"New from Template",templatesMenu:"New from Template…",templatesNote:"Replaces the pages, swatches and styles of this document. Undo brings them back.","template.editorial":"Editorial","template.event":"Event","template.sale":"Promotion","template.quote":"Quote",homeTab:"Home","home.frames":"Frames","home.place":"Place Image","home.styles":"Styles","home.output":"Output"},vj={summary:"{pages} 页",summaryOne:"{pages} 页",selectedCount:"已选 {count} 个",addPage:"添加页面",newLayer:"新建图层",hideLayer:"隐藏图层",showLayer:"显示图层",lockLayer:"锁定图层",unlockLayer:"解锁图层",nothingSelected:"选择一个对象或一段文字以查看其属性。",positionX:"X 位置",positionY:"Y 位置",width:"宽度",height:"高度",rotation:"旋转角度",flipHorizontal:"水平翻转",flipVertical:"垂直翻转",tint:"色调",strokeWeight:"粗细",cornerRadius:"圆角半径",fontSize:"字号",fontStyle:"字体样式",leading:"行距",auto:"自动",tracking:"字距",alignment:"对齐","align.left":"左对齐","align.center":"居中对齐","align.right":"右对齐","align.justify":"两端对齐",parentItems:"{count} 个对象",noParent:"[无]",newParent:"新建主页",pageParent:"页面的主页",movePageUp:"上移页面",movePageDown:"下移页面",duplicateSpread:"直接复制跨页",deletePage:"删除页面",collapse:"折叠",expand:"展开",renameLayer:"图层名称",renameObject:"对象名称",hideObject:"隐藏对象",showObject:"显示对象",lockObject:"锁定对象",unlockObject:"解锁对象",layerUp:"上移图层",layerDown:"下移图层",swatchTarget:"应用于",newSwatch:"新建色板",deleteSwatch:"删除色板",swatchName:"名称",swatchNameHint:"以颜色值命名",swatchColor:"颜色",cancel:"取消",ok:"确定",newParagraphStyle:"用所选内容新建段落样式",newCharacterStyle:"用所选内容新建字符样式",newParagraphStyleName:"段落样式",newCharacterStyleName:"字符样式",editStyle:"编辑样式",deleteStyle:"删除样式",styleOptions:"样式选项:{name}",styleName:"样式名称",unchanged:"保持不变",noLinks:"没有置入的图形。",goToLink:"选择其框架",relink:"重新链接",placeImage:"置入图像",placePurpose:"置入一张图像",relinkPurpose:"重新链接 {name}",ppi:"{ppi} ppi","link.ok":"已链接","link.modified":"已修改","link.missing":"缺失","link.embedded":"已嵌入",documentSetup:"文档设置",presets:"尺寸","preset.letter":"Letter","preset.a4":"A4","preset.poster":"海报","preset.square":"方形","preset.story":"快拍","preset.landscape":"横幅","presetSize.letter":"8.5 × 11 英寸","presetSize.a4":"210 × 297 毫米","presetSize.poster":"1080 × 1440 像素","presetSize.square":"1080 × 1080 像素","presetSize.story":"1080 × 1920 像素","presetSize.landscape":"1920 × 1080 像素",presetCustom:"页面大小:{size}",units:"单位","unit.pt":"点","unit.px":"像素","unit.mm":"毫米","unit.in":"英寸",intent:"用途","intent.print":"打印","intent.web":"Web","intent.mobile":"移动设备",margins:"边距",bleed:"出血",columns:"栏数",gutter:"栏间距",facingPages:"对页",export:"导出",exportAction:"导出",exported:"已导出 {count} 个文件",exportFailed:"无法导出",format:"格式","format.png":"PNG 图像","format.jpeg":"JPEG 图像","format.pdf":"PDF","format.idml":"InDesign 标记 (IDML)","format.epub":"EPUB","format.html":"HTML",pages:"页面",allPages:"全部页面({count})",currentPage:"第 {page} 页",pageRange:"范围",includeBleed:"包含出血",resolution:"分辨率",scale:"{scale}×({ppi} ppi)",transparentBackground:"透明背景",quality:"品质",exportMenu:"导出…",documentSetupMenu:"文档设置…",sizes:"尺寸",newSize:"新建尺寸",deleteSize:"删除尺寸",originalSize:"原始",sizeOf:"{width} × {height}",sizeName:"名称",sizeNameTaken:"已有同名尺寸。",sizeNote:"按此尺寸复制原始版面;对象按其自适应规则调整。",allSizes:"全部尺寸({count})",pageBackground:"页面背景",backgroundColor:"背景颜色",noBackground:"无(透明)",templates:"从模板新建",templatesMenu:"从模板新建…",templatesNote:"将替换本文档的页面、色板和样式。撤销可恢复。","template.editorial":"社论","template.event":"活动","template.sale":"促销","template.quote":"引言",homeTab:"开始","home.frames":"框架","home.place":"置入图像","home.styles":"样式","home.output":"输出"},Yg={"en-US":mj,"zh-CN":vj},pj={"zh-CN":{File:"文件",Edit:"编辑",Layout:"版面",Type:"文字",Object:"对象",Table:"表",View:"视图",Window:"窗口",Help:"帮助",Pages:"页面",Layers:"图层",Swatches:"色板","Paragraph Styles":"段落样式","Character Styles":"字符样式",Selection:"选择","Direct Selection":"直接选择",Page:"页面",Gap:"间隙","Type on a Path":"路径文字","Vertical Type":"直排文字",Line:"直线",Pen:"钢笔",Pencil:"铅笔","Rectangle Frame":"矩形框架","Ellipse Frame":"椭圆框架","Polygon Frame":"多边形框架",Rectangle:"矩形",Ellipse:"椭圆",Polygon:"多边形",Scissors:"剪刀","Free Transform":"自由变换",Rotate:"旋转",Scale:"缩放",Shear:"切变","Gradient Swatch":"渐变色板","Gradient Feather":"渐变羽化",Eyedropper:"吸管",Measure:"度量",Hand:"抓手",Zoom:"缩放显示",Properties:"属性",Fill:"填色",Stroke:"描边",Opacity:"不透明度",Font:"字体","Paragraph Style":"段落样式","Character Style":"字符样式","Document Setup":"文档设置",Group:"编组",Ungroup:"取消编组",Duplicate:"直接复制",Clear:"清除",Links:"链接","<group>":"<组>","<text frame>":"<文本框架>","<image>":"<图像>","<rectangle>":"<矩形>","<ellipse>":"<椭圆>","<polygon>":"<多边形>","<line>":"<直线>","<path>":"<路径>","Show Text Threads":"显示文本串接",Extras:"附注","Fit Text to Frame":"使文本适合框架",Fitting:"适合"}},yj=[0,0,0,0];function gj(l){var c,f,o,d,p;const s=l.inspected,u=((c=s.canvas)==null?void 0:c.spreads)??[];return{spreads:(s.spreads??[]).map((y,g)=>{const v=u[g]??{x:0,y:0,width:l.width,height:l.height},b=(y.pages??[]).map((M,z)=>({index:M.index??z,name:M.name??"",bounds:M.bounds??yj,parent:M.parent??null,margins:M.margins??null,columns:M.columns??1,background:M.background??null}));return{index:y.index??g,area:{x0:v.x,y0:v.y,x1:v.x+v.width,y1:v.y+v.height},pages:b,items:y.items??[],left:b.length?Math.min(...b.map(M=>M.bounds[0])):0}}),pageCount:s.pageCount??0,selected:((o=(f=s.selection)==null?void 0:f.items)==null?void 0:o.length)??0,selection:((d=s.selection)==null?void 0:d.items)??[],editingText:((p=s.selection)==null?void 0:p.text)!=null,layers:s.layers??[],activeLayer:s.activeLayer??null,swatches:s.swatches??[],swatchColors:s.swatchColors??(s.swatches??[]).map(y=>({name:y,kind:"color",color:null,locked:!1})),paragraphStyles:s.paragraphStyles??[],characterStyles:s.characterStyles??[],stories:s.stories??[],parents:s.parents??[],layouts:s.layouts??[],settings:{pageWidth:612,pageHeight:792,facingPages:!1,intent:"print",...s.settings},tool:s.tool??"selection"}}function $g(l,s,u){let c=null,f=Number.POSITIVE_INFINITY;for(const o of l.spreads){const{x0:d,y0:p,x1:y,y1:g}=o.area,v=s<d?d-s:s>y?s-y:0,b=u<p?p-u:u>g?u-g:0,M=Math.hypot(v,b);M<f&&(f=M,c=o)}return c}function Xg(l,s=0,u=[]){var c;for(let f=l.length-1;f>=0;f-=1){const o=l[f];u.push({item:o,depth:s}),(c=o.children)!=null&&c.length&&Xg(o.children,s+1,u)}return u}function Mj(l,s){const u=c=>{for(const f of c){if(f.id===s)return f;const o=f.children?u(f.children):null;if(o)return o}return null};for(const c of l.spreads){const f=u(c.items);if(f)return{item:f,spread:c}}return null}const bj=["File","Edit","Layout","Type","Object","Table","View","Window","Help"],wj={File:["file.package"],Edit:["edit.undo","edit.redo","edit.cut","edit.copy","edit.paste","edit.duplicate","edit.stepAndRepeat","find.find"],Layout:["layout.pages.insert","layout.parents.new","layout.marginsAndColumns","layout.createGuides","toc.generate","layout.section"],Type:["footnote.insert","type.createOutlines","type.changeCase","hyperlink.create","list.define","type.fillWithPlaceholder"],Object:["object.group","object.ungroup","object.bringForward","object.sendBackward","object.fit","object.textFrameOptions","object.dropShadow","object.lock"],Table:["table.insertRowBelow","table.insertColumnRight","table.deleteRow","table.deleteColumn","table.merge","table.unmerge","table.convertFromText"],View:["guide.deleteAll","view.showTextThreads"],Window:["object.textWrap","preflight.run","article.new"]},Kg=["note","colorTheme","contentCollector","contentPlacer"],F1=[...cA,"pdf","psd","eps","svg"];function Sj({info:l}){const{run:s,phrase:u,t:c}=Ne(),f=ml(),{can:o,pick:d}=_g(),p=o&&!f,y=Ln("links.list",{})??[],g=async M=>{const z=await d(c("placePurpose"),F1);z&&await s("file.place",{base64:X1(z.bytes),name:z.name,...M!=null?{frame:M}:{}})},v=async M=>{const z=await d(c("relinkPurpose",{name:M.name}),F1);if(z)for(const x of M.uses)await s("file.place",{base64:X1(z.bytes),name:z.name,frame:x.id})},b=l.selection.length===1?l.selection[0]:void 0;return h.jsxs(_n,{title:u("Links"),defaultOpen:!1,testId:"layout-links",children:[y.length?null:h.jsx("p",{className:"layout-empty",children:c("noLinks")}),y.map(M=>{const z=M.uses.map(x=>x.ppi).filter(x=>x!=null);return h.jsxs("div",{className:"layout-row layout-link-row","data-status":M.status,"data-testid":`layout-link-${M.asset}`,children:[h.jsx("span",{className:"layout-row-text",title:M.name,children:M.name}),h.jsx("span",{className:"layout-badge","data-status":M.status,children:c(`link.${M.status}`)}),z.length?h.jsx("span",{className:"kui-muted layout-count",children:c("ppi",{ppi:Math.round(Math.min(...z))})}):null,h.jsx(Ge,{icon:_C,label:c("goToLink"),onClick:()=>void s("links.goTo",{asset:M.asset}),"data-testid":`layout-link-go-${M.asset}`}),p?h.jsx(Ge,{icon:r0,label:c("relink"),onClick:()=>void v(M),"data-testid":`layout-link-relink-${M.asset}`}):null]},M.asset)}),h.jsx(hi,{end:p?h.jsx(Ge,{icon:O4,label:c("placeImage"),onClick:()=>void g(b),"data-testid":"layout-place-image"}):null})]})}function ol({id:l,primary:s,size:u="large"}){const c=mi(),{phrase:f}=Ne(),o=c==null?void 0:c.tools.find(d=>d.id===l);return o?h.jsx($k,{tool:l,icon:M0(o.icon,l),label:f(o.label),size:u,testId:`layout-home-tool-${l}`,primary:s}):null}function zj({onDialog:l}){const{run:s,enabled:u,phrase:c,t:f,session:o}=Ne(),d=o.state,{can:p,pick:y}=_g(),g=async()=>{const v=await y(f("placePurpose"),F1);if(!v)return;const b=(d==null?void 0:d.selection.length)===1?d.selection[0]:void 0;await s("file.place",{base64:X1(v.bytes),name:v.name,...b!=null?{frame:b}:{}})};return h.jsxs(h.Fragment,{children:[h.jsxs(Rn,{label:f("home.frames"),icon:ps,children:[h.jsx(ol,{id:"type"}),h.jsx(ol,{id:"rectangleFrame"}),h.jsx(ol,{id:"rectangle"}),h.jsx(ol,{id:"line"}),h.jsxs(lu,{children:[h.jsx(ol,{id:"ellipseFrame",size:"small"}),h.jsx(ol,{id:"ellipse",size:"small"}),h.jsx(ol,{id:"pen",size:"small"})]}),h.jsx(St,{icon:O4,label:f("home.place"),size:"large",disabled:!p||!u("file.place"),onClick:()=>void g(),"data-testid":"layout-home-place",primary:!0})]}),h.jsxs(Rn,{label:c("Pages"),icon:hm,children:[h.jsx(si,{command:"layout.pages.insert",params:{count:1},icon:hm,size:"large",primary:!0}),h.jsxs(lu,{children:[h.jsx(si,{command:"layout.parents.new",icon:A1,primary:!0}),h.jsx(St,{icon:Z4,label:f("documentSetupMenu"),onClick:()=>l("setup"),"data-testid":"layout-home-document-setup",primary:!0})]})]}),h.jsxs(Rn,{label:f("home.styles"),icon:O1,children:[h.jsx(qm,{icon:O1,label:c("Paragraph Styles"),size:"large",disabled:!u("style.paragraph.apply"),testId:"layout-home-paragraph-style",primary:!0,children:((d==null?void 0:d.paragraphStyles)??[]).map(v=>h.jsx(Bt,{label:v,onSelect:()=>void s("style.paragraph.apply",{name:v}),testId:`layout-home-paragraph-style-${v}`},v))}),h.jsx(qm,{icon:Tu,label:c("Character Styles"),disabled:!u("style.character.apply"),testId:"layout-home-character-style",children:((d==null?void 0:d.characterStyles)??[]).map(v=>h.jsx(Bt,{label:v,onSelect:()=>void s("style.character.apply",{name:v}),testId:`layout-home-character-style-${v}`},v))})]}),h.jsxs(Rn,{label:c("Arrange"),icon:ys,children:[h.jsx(si,{command:"object.group",icon:ys,size:"large",primary:!0}),h.jsxs(lu,{children:[h.jsx(si,{command:"object.ungroup",icon:ku}),h.jsx(si,{command:"object.bringForward",icon:t0}),h.jsx(si,{command:"object.sendBackward",icon:I4})]})]}),h.jsxs(Rn,{label:f("home.output"),icon:E1,children:[h.jsx(St,{icon:E1,label:f("exportMenu"),size:"large",onClick:()=>l("export"),"data-testid":"layout-home-export",primary:!0}),h.jsx(St,{icon:A1,label:f("templatesMenu"),onClick:()=>l("templates"),"data-testid":"layout-home-templates",primary:!0})]})]})}const ri=26,s5=14,r5=6;function xj({info:l,spread:s}){const{run:u,phrase:c,t:f}=Ne(),o=ml(),[d,p]=w.useState(new Set),[y,g]=w.useState(0),[v,b]=w.useState(null),M=w.useMemo(()=>{const J=Xg((s==null?void 0:s.items)??[]),$=[];for(const le of l.layers){const Z=J.filter(({item:se,depth:ae})=>ae===0&&se.layer===le.id).length;if($.push({kind:"layer",layer:le,count:Z}),d.has(le.id))continue;let ie=!1;for(const se of J)se.depth===0&&(ie=se.item.layer===le.id),ie&&$.push({kind:"item",item:se.item,depth:se.depth})}return $},[d,l.layers,s]),z=new Set(l.selection),x=Math.max(0,Math.floor(y/ri)-r5),E=Math.min(M.length,Math.ceil((y+s5*ri)/ri)+r5),T=l.layers.findIndex(J=>J.id===l.activeLayer),C=(J,$)=>void u(J.shiftKey?"selection.toggle":"selection.set",J.shiftKey?{id:$}:{ids:[$]}),N=J=>{const $=v;b(null),!(!J||!$)&&($.layer?u("layer.set",{id:$.id,name:$.text}):u("object.rename",{id:$.id,name:$.text}))},G=(J,$)=>{const le=$*ri;if(J.kind==="layer"){const{layer:ae}=J,de=!d.has(ae.id);return h.jsxs("div",{className:"layout-row layout-layer-row",style:{top:le},"data-active":ae.id===l.activeLayer,"data-testid":`layout-layer-${ae.id}`,children:[h.jsx(Ge,{icon:ae.visible?vs:ou,label:ae.visible?f("hideLayer"):f("showLayer"),pressed:!ae.visible,disabled:o,onClick:()=>void u("layer.set",{id:ae.id,visible:!ae.visible}),"data-testid":`layout-layer-visibility-${ae.id}`}),h.jsx(Ge,{icon:ae.locked?gs:N1,label:ae.locked?f("unlockLayer"):f("lockLayer"),pressed:ae.locked,disabled:o,onClick:()=>void u("layer.set",{id:ae.id,locked:!ae.locked}),"data-testid":`layout-layer-lock-${ae.id}`}),h.jsx("button",{type:"button",className:"layout-disclosure","aria-expanded":de,"aria-label":f(de?"collapse":"expand"),onClick:()=>p(q=>{const ue=new Set(q);return de?ue.add(ae.id):ue.delete(ae.id),ue}),children:de?h.jsx(ci,{size:13,"aria-hidden":"true"}):h.jsx(ws,{size:13,"aria-hidden":"true"})}),h.jsx("span",{className:"layout-layer-color",style:{background:`rgb(${ae.color.join(",")})`},"aria-hidden":"true"}),v!=null&&v.layer&&v.id===ae.id?h.jsx(ym,{value:v.text,label:f("renameLayer"),onChange:q=>b({...v,text:q}),onDone:N,testId:"layout-rename"}):h.jsx("button",{type:"button",className:"layout-row-name",onClick:()=>void u("layer.activate",{id:ae.id}),onDoubleClick:()=>!o&&b({id:ae.id,layer:!0,text:ae.name}),children:ae.name}),h.jsx("span",{className:"kui-muted layout-count",children:J.count})]},`layer-${ae.id}`)}const{item:Z,depth:ie}=J,se=Z.name||c(Z.kind);return h.jsxs("div",{className:"layout-row layout-item-row",style:{top:le},"data-selected":z.has(Z.id),"data-testid":`layout-object-${Z.id}`,children:[h.jsx(Ge,{icon:Z.hidden?ou:vs,label:Z.hidden?f("showObject"):f("hideObject"),pressed:Z.hidden,disabled:o,onClick:()=>void u("object.setFlags",{ids:[Z.id],hidden:!Z.hidden}),"data-testid":`layout-object-visibility-${Z.id}`}),h.jsx(Ge,{icon:Z.locked?gs:N1,label:Z.locked?f("unlockObject"):f("lockObject"),pressed:Z.locked,disabled:o,onClick:()=>void u("object.setFlags",{ids:[Z.id],locked:!Z.locked}),"data-testid":`layout-object-lock-${Z.id}`}),h.jsx("span",{style:{width:14+ie*12,flex:"none"},"aria-hidden":"true"}),v&&!v.layer&&v.id===Z.id?h.jsx(ym,{value:v.text,label:f("renameObject"),onChange:ae=>b({...v,text:ae}),onDone:N,testId:"layout-rename"}):h.jsx("button",{type:"button",className:"layout-row-name",onClick:ae=>C(ae,Z.id),onDoubleClick:()=>!o&&b({id:Z.id,layer:!1,text:se}),"data-testid":`layout-object-name-${Z.id}`,children:se})]},`item-${Z.id}`)};return h.jsxs(_n,{title:c("Layers"),actions:h.jsx(Ge,{icon:Dn,label:f("newLayer"),disabled:o,onClick:()=>void u("layer.new",{}),"data-testid":"layout-new-layer"}),testId:"layout-layers",children:[h.jsx("div",{className:"layout-virtual",style:{height:Math.min(M.length,s5)*ri},onScroll:J=>g(J.currentTarget.scrollTop),"data-testid":"layout-layer-list","data-rows":M.length,children:h.jsx("div",{style:{height:M.length*ri,position:"relative"},children:M.slice(x,E).map((J,$)=>G(J,x+$))})}),h.jsx(hi,{start:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:cu,label:f("layerUp"),disabled:o||T<=0,onClick:()=>l.activeLayer!=null&&void u("layer.move",{id:l.activeLayer,to:T-1}),"data-testid":"layout-layer-up"}),h.jsx(Ge,{icon:uu,label:f("layerDown"),disabled:o||T<0||T+1>=l.layers.length,onClick:()=>l.activeLayer!=null&&void u("layer.move",{id:l.activeLayer,to:T+1}),"data-testid":"layout-layer-down"})]}),end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:ys,label:c("Group"),disabled:o||l.selection.length<2,onClick:()=>void u("object.group",{ids:l.selection}),"data-testid":"layout-group"}),h.jsx(Ge,{icon:ku,label:c("Ungroup"),disabled:o||!l.selection.length,onClick:()=>void u("object.ungroup",{ids:l.selection}),"data-testid":"layout-ungroup"}),h.jsx(Ge,{icon:di,label:c("Duplicate"),disabled:o||!l.selection.length,onClick:()=>void u("edit.duplicate",{}),"data-testid":"layout-duplicate"}),h.jsx(Ge,{icon:Hn,label:c("Clear"),disabled:o||!l.selection.length,onClick:()=>void u("edit.clear",{}),"data-testid":"layout-delete"})]})})]})}const u5=92;function Cj({spread:l}){const{session:s}=Ne(),{doc:u,change:c}=s,[f,o]=w.useState(null),d=l.area.x1-l.area.x0,p=l.area.y1-l.area.y0,y=Math.min(u5/Math.max(1,d),u5/Math.max(1,p)),g=Math.max(1,Math.round(d*y)),v=Math.max(1,Math.round(p*y));return w.useEffect(()=>{if(!u||!f)return;let b=!1;const M=window.setTimeout(async()=>{var x;const z=await u.render(l.area.x0,l.area.y0,y,g,v).catch(()=>null);b||!z||(f.width=g,f.height=v,(x=f.getContext("2d"))==null||x.putImageData(new ImageData(new Uint8ClampedArray(z.buffer,z.byteOffset,z.byteLength),g,v),0,0))},300);return()=>{b=!0,window.clearTimeout(M)}},[f,c.revision,u,v,y,l.area.x0,l.area.y0,g]),h.jsx("canvas",{ref:o,width:g,height:v,className:"layout-thumb"})}function Ej({info:l,onShow:s,onSetup:u}){var z;const{run:c,phrase:f,t:o}=Ne(),d=ml(),[p,y]=w.useState(0),g=Math.min(p,Math.max(0,l.pageCount-1)),v=l.spreads.find(x=>x.pages.some(E=>E.index===g)),b=((z=v==null?void 0:v.pages.find(x=>x.index===g))==null?void 0:z.parent)??null,M=l.parents.filter(x=>x.label).map(x=>[x.label??"",x.label??""]);return h.jsxs(_n,{title:f("Pages"),actions:h.jsx(Ge,{icon:Dn,label:o("addPage"),disabled:d,onClick:()=>void c("layout.pages.insert",{count:1,after:g}),"data-testid":"layout-add-page"}),testId:"layout-pages-panel",children:[h.jsxs("div",{className:"layout-parents","data-testid":"layout-parents",children:[l.parents.map(x=>h.jsx("span",{className:"layout-parent",title:o("parentItems",{count:x.items}),children:x.label??o("noParent")},x.id)),h.jsx(Ge,{icon:Dn,label:o("newParent"),disabled:d,onClick:()=>void c("layout.parents.new",{}),"data-testid":"layout-new-parent"})]}),h.jsx("div",{className:"layout-spreads",children:l.spreads.map(x=>h.jsxs("div",{className:"layout-spread-cell",children:[h.jsx("button",{type:"button",className:"layout-spread",onClick:()=>s(x),"data-testid":`layout-spread-${x.index}`,children:h.jsx(Cj,{spread:x})}),h.jsx("span",{className:"layout-page-names",children:x.pages.map(E=>h.jsx("button",{type:"button",className:"layout-page-name","data-active":E.index===g,onClick:()=>y(E.index),"data-testid":`layout-page-${E.index}`,children:E.name},E.index))})]},x.index))}),h.jsx("fieldset",{className:"layout-stack layout-fieldset",disabled:d,children:h.jsx(Da,{label:o("pageParent"),value:b??"",choices:[["",o("noParent")],...M],onChange:x=>void c("layout.pages.applyParent",{pages:[g+1],parent:x||null}),testId:"layout-page-parent"})}),h.jsx(hi,{start:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:cu,label:o("movePageUp"),disabled:d||g===0,onClick:()=>void c("layout.pages.move",{from:g,to:g-1}).then(()=>y(g-1)),"data-testid":"layout-page-up"}),h.jsx(Ge,{icon:uu,label:o("movePageDown"),disabled:d||g+1>=l.pageCount,onClick:()=>void c("layout.pages.move",{from:g,to:g+1}).then(()=>y(g+1)),"data-testid":"layout-page-down"})]}),end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:Z4,label:f("Document Setup"),disabled:d,onClick:u,"data-testid":"layout-document-setup"}),h.jsx(Ge,{icon:di,label:o("duplicateSpread"),disabled:d||!v,onClick:()=>v&&void c("layout.pages.duplicateSpread",{spread:v.index}),"data-testid":"layout-duplicate-spread"}),h.jsx(Ge,{icon:Hn,label:o("deletePage"),disabled:d||l.pageCount<2,onClick:()=>void c("layout.pages.delete",{pages:[g]}),"data-testid":"layout-delete-page"})]})})]})}const Tj=[["left",VE],["center",_E],["right",UE],["justify",BE]];function kj(l,s){const u=l.map(c=>[c,c]);return s&&!l.includes(s)?[[s,s],...u]:u}const _t=l=>Math.round(l*100)/100;function Aj({info:l}){const{t:s,phrase:u}=Ne(),c=ml(),f=l.selection.length?Mj(l,l.selection[0]):null,o=f==null?void 0:f.item,d=l.editingText||(o==null?void 0:o.story)!=null;return!o&&!l.editingText?h.jsxs(_n,{title:u("Properties"),testId:"layout-properties",children:[h.jsx("p",{className:"layout-empty",children:s("nothingSelected")}),h.jsx("fieldset",{className:"layout-fieldset",disabled:c,children:h.jsx(jj,{info:l})})]}):h.jsx(_n,{title:u("Properties"),testId:"layout-properties",children:h.jsxs("fieldset",{className:"layout-fieldset",disabled:c,children:[o&&!l.editingText?h.jsx(Nj,{info:l,item:o}):null,o&&!l.editingText?h.jsx(Oj,{info:l,item:o}):null,d?h.jsx(Rj,{info:l}):null]})})}function jj({info:l}){var p,y,g;const{run:s,t:u}=Ne(),c=((y=(p=l.spreads[0])==null?void 0:p.pages[0])==null?void 0:y.background)??"",f=l.swatchColors.filter(v=>v.kind==="color"||v.kind==="tint"||v.kind==="paper"),o=((g=f.find(v=>v.name===c))==null?void 0:g.color)??"#ffffff",d=[["",u("noBackground")],...f.map(v=>[v.name,v.name])];return c&&!f.some(v=>v.name===c)&&d.push([c,c]),h.jsx("div",{className:"layout-stack","data-testid":"layout-page-background",children:h.jsxs("span",{className:"layout-color",children:[h.jsx(Da,{label:u("pageBackground"),value:c,choices:d,onChange:v=>void s("page.background",{color:v||null}),testId:"layout-background"}),h.jsx("input",{type:"color","aria-label":u("backgroundColor"),value:o,onChange:v=>void s("page.background",{color:v.target.value}),"data-testid":"layout-background-color"})]})})}function Nj({info:l,item:s}){const{run:u,t:c}=Ne(),f=Ln("transform.info",{ids:l.selection},l.selection.join(","));if(!f)return null;const o=d=>(p,y)=>{y&&Number.isFinite(p)&&u("transform.set",{[d]:p,ids:l.selection,...d==="rotation"?{}:{ref:0}})};return h.jsxs("div",{className:"layout-grid","data-testid":"layout-geometry","data-item":s.id,children:[h.jsx(xa,{label:"X",name:c("positionX"),value:_t(f.x),min:-1e5,max:1e5,step:1,unit:"pt",onChange:o("x"),testId:"layout-x"}),h.jsx(xa,{label:"Y",name:c("positionY"),value:_t(f.y),min:-1e5,max:1e5,step:1,unit:"pt",onChange:o("y"),testId:"layout-y"}),h.jsx(xa,{label:"W",name:c("width"),value:_t(f.width),min:.1,max:1e5,step:1,unit:"pt",onChange:o("width"),testId:"layout-w"}),h.jsx(xa,{label:"H",name:c("height"),value:_t(f.height),min:.1,max:1e5,step:1,unit:"pt",onChange:o("height"),testId:"layout-h"}),h.jsx(xa,{label:"∠",name:c("rotation"),value:_t(f.rotation),min:-360,max:360,step:1,unit:"°",onChange:o("rotation"),testId:"layout-rotation"}),h.jsxs("span",{className:"layout-buttons",children:[h.jsx("button",{type:"button",className:"kui-icon-button","aria-label":c("flipHorizontal"),title:c("flipHorizontal"),onClick:()=>void u("transform.flip",{axis:"horizontal",ids:l.selection}),"data-testid":"layout-flip-h",children:h.jsx(Vx,{size:16,"aria-hidden":"true"})}),h.jsx("button",{type:"button",className:"kui-icon-button","aria-label":c("flipVertical"),title:c("flipVertical"),onClick:()=>void u("transform.flip",{axis:"vertical",ids:l.selection}),"data-testid":"layout-flip-v",children:h.jsx(a0,{size:16,"aria-hidden":"true"})})]})]})}function Oj({info:l,item:s}){const{run:u,t:c,phrase:f}=Ne(),o=l.selection,d=l.swatchColors.filter(y=>y.kind!=="registration").map(y=>[y.name,y.name]),p=y=>d.some(([g])=>g===y)?d:[[y,y],...d];return h.jsxs("div",{className:"layout-stack","data-testid":"layout-appearance",children:[h.jsx(Da,{label:f("Fill"),value:s.fill,choices:p(s.fill),onChange:y=>void u("object.fill",{swatch:y,ids:o}),testId:"layout-fill"}),h.jsx(xa,{label:c("tint"),value:Math.round((s.fillTint??1)*100),min:0,max:100,step:1,unit:"%",track:!0,onChange:(y,g)=>g&&void u("object.fill",{swatch:s.fill,tint:y/100,ids:o}),testId:"layout-tint"}),h.jsx(Da,{label:f("Stroke"),value:s.stroke.swatch,choices:p(s.stroke.swatch),onChange:y=>void u("object.stroke",{swatch:y,ids:o}),testId:"layout-stroke"}),h.jsx(xa,{label:c("strokeWeight"),value:_t(s.stroke.weight),min:0,max:1e3,step:.5,unit:"pt",onChange:(y,g)=>g&&void u("object.stroke",{weight:y,ids:o}),testId:"layout-stroke-weight"}),h.jsx(xa,{label:f("Opacity"),value:Math.round((s.opacity??1)*100),min:0,max:100,step:1,unit:"%",track:!0,onChange:(y,g)=>g&&void u("object.opacity",{opacity:y/100,ids:o}),testId:"layout-opacity"}),h.jsx(xa,{label:c("cornerRadius"),value:_t(s.corner&&s.corner.shape!=="none"?s.corner.size:0),min:0,max:1e4,step:1,unit:"pt",onChange:(y,g)=>g&&void u("object.cornerOptions",{shape:y>0?"rounded":"none",size:y,ids:o}),testId:"layout-corner"})]})}function Rj({info:l}){var z,x,E;const{run:s,t:u,phrase:c,session:f}=Ne(),o=Ln("type.selectionAttrs",{},`${l.selection.join(",")}:${l.editingText}`),d=Ln("font.families",{},f.doc?"families":null),p=((z=o==null?void 0:o.chars)==null?void 0:z.fontFamily)??"",y=Ln("font.families",{family:p},p);if(!o)return null;const g=o.chars??{},v=(d??[]).map(T=>[T,T]);p&&!v.some(([T])=>T===p)&&v.unshift([p,p]);const b=T=>void s("type.char",{attrs:T}),M=((x=g.leading)==null?void 0:x.kind)==="points"?g.leading.value??0:0;return h.jsxs("div",{className:"layout-stack","data-testid":"layout-typography",children:[h.jsx(Da,{label:c("Font"),value:p,choices:v,onChange:T=>b({fontFamily:T}),testId:"layout-font"}),h.jsx(Da,{label:u("fontStyle"),value:g.fontStyle??"Regular",choices:kj((y==null?void 0:y.styles)??[],g.fontStyle),onChange:T=>b({fontStyle:T}),testId:"layout-font-style"}),h.jsxs("div",{className:"layout-grid",children:[h.jsx(xa,{label:u("fontSize"),value:_t(g.size??12),min:.1,max:1296,step:.5,unit:"pt",onChange:(T,C)=>C&&b({size:T}),testId:"layout-font-size"}),h.jsx(xa,{label:u("leading"),value:_t(M),min:0,max:5e3,step:.5,unit:M?"pt":u("auto"),onChange:(T,C)=>C&&b({leading:T>0?{kind:"points",value:T}:{kind:"auto"}}),testId:"layout-leading"}),h.jsx(xa,{label:u("tracking"),value:_t(g.tracking??0),min:-1e3,max:1e4,step:5,onChange:(T,C)=>C&&b({tracking:T}),testId:"layout-tracking"})]}),h.jsx(hg,{label:u("alignment"),value:((E=o.para)==null?void 0:E.align)??"left",segments:Tj.map(([T,C])=>({value:T,icon:C,label:u(`align.${T}`)})),onChange:T=>void s("type.para",{attrs:{align:T}}),testId:"layout-align"}),h.jsx(ua,{onClick:()=>void s("frame.fitText",l.editingText?{}:{ids:l.selection}),"data-testid":"layout-fit-text",children:c("Fit Text to Frame")}),h.jsx(Da,{label:c("Paragraph Style"),value:o.paragraphStyle??"",choices:l.paragraphStyles.map(T=>[T,T]),onChange:T=>void s("style.paragraph.apply",{name:T}),testId:"layout-paragraph-style-choice"}),h.jsx(Da,{label:c("Character Style"),value:o.characterStyle??"[None]",choices:l.characterStyles.map(T=>[T,T]),onChange:T=>void s("style.character.apply",{name:T}),testId:"layout-character-style-choice"})]})}const c5={pt:1,px:1,mm:72/25.4,in:72},ms=[{id:"letter",width:612,height:792,intent:"print",unit:"in"},{id:"a4",width:595.276,height:841.89,intent:"print",unit:"mm"},{id:"poster",width:1080,height:1440,intent:"web",unit:"px"},{id:"square",width:1080,height:1080,intent:"web",unit:"px"},{id:"story",width:1080,height:1920,intent:"mobile",unit:"px"},{id:"landscape",width:1920,height:1080,intent:"web",unit:"px"}];function Su(l,s){var c;const u=(f,o)=>Math.abs(f-o)<.5;return((c=ms.find(f=>u(f.width,l)&&u(f.height,s)))==null?void 0:c.id)??"custom"}function Lj({info:l,onClose:s}){var ue,we;const{run:u,t:c}=Ne(),f=(ue=l.spreads[0])==null?void 0:ue.pages[0],[o,d]=w.useState(l.settings.pageWidth),[p,y]=w.useState(l.settings.pageHeight),[g,v]=w.useState(()=>{var D;return((D=ms.find(L=>L.id===Su(l.settings.pageWidth,l.settings.pageHeight)))==null?void 0:D.unit)??"pt"}),[b,M]=w.useState(l.settings.intent||"print"),[z,x]=w.useState(l.settings.facingPages),[E,T]=w.useState(((we=f==null?void 0:f.margins)==null?void 0:we.top)??36),[C,N]=w.useState((f==null?void 0:f.columns)??1),[G,J]=w.useState(12),[$,le]=w.useState(0),Z=Su(o,p),ie=c5[g],se=D=>Math.round(D/ie*100)/100,ae=D=>{const L=ms.find(P=>P.id===D);L&&(d(L.width),y(L.height),v(L.unit),M(L.intent),L.intent!=="print"&&x(!1))},de=async()=>{await u("layout.documentSetup",{width:o,height:p,facingPages:z,intent:b,bleed:$}),await u("layout.marginsAndColumns",{margins:E,columns:C,gutter:G}),s()},q=(D,L,P,re,pe=.01)=>h.jsx(xa,{label:D,value:se(L),min:pe,max:1e5,step:g==="in"?.01:1,unit:g,onChange:(I,ye)=>ye&&P(I*ie),testId:re});return h.jsxs(Un,{title:c("documentSetup"),onClose:s,testId:"layout-setup-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:s,children:c("cancel")}),h.jsx(ua,{variant:"primary",onClick:()=>void de(),"data-testid":"layout-setup-ok",children:c("ok")})]}),children:[h.jsx("div",{className:"layout-presets",role:"radiogroup","aria-label":c("presets"),children:ms.map(D=>h.jsxs("button",{type:"button",role:"radio","aria-checked":Z===D.id,className:"layout-preset","data-active":Z===D.id,onClick:()=>ae(D.id),"data-testid":`layout-preset-${D.id}`,children:[h.jsx("span",{className:"layout-preset-shape",style:{aspectRatio:`${D.width} / ${D.height}`},"aria-hidden":"true"}),h.jsx("span",{children:c(`preset.${D.id}`)}),h.jsx("span",{className:"kui-muted",children:D.unit==="px"?`${D.width} × ${D.height} px`:c(`presetSize.${D.id}`)})]},D.id))}),h.jsxs("div",{className:"layout-grid",children:[h.jsx(Da,{label:c("units"),value:g,choices:Object.keys(c5).map(D=>[D,c(`unit.${D}`)]),onChange:v,testId:"layout-setup-unit"}),h.jsx(Da,{label:c("intent"),value:b,choices:["print","web","mobile"].map(D=>[D,c(`intent.${D}`)]),onChange:M,testId:"layout-setup-intent"}),q(c("width"),o,d,"layout-setup-width"),q(c("height"),p,y,"layout-setup-height"),q(c("margins"),E,T,"layout-setup-margins",0),q(c("bleed"),$,le,"layout-setup-bleed",0),h.jsx(xa,{label:c("columns"),value:C,min:1,max:216,step:1,onChange:(D,L)=>L&&N(Math.round(D)),testId:"layout-setup-columns"}),q(c("gutter"),G,J,"layout-setup-gutter",0)]}),h.jsx(H1,{label:c("facingPages"),checked:z,onChange:x,testId:"layout-setup-facing"}),h.jsx("p",{className:"kui-muted layout-note",children:c("presetCustom",{size:`${se(o)} × ${se(p)} ${g}`})})]})}const z1=ms.filter(l=>l.unit==="px"),zu=l=>Math.round(l*100)/100;function Dj({info:l,onShow:s}){const{run:u,t:c}=Ne(),f=ml(),[o,d]=w.useState(null),[p,y]=w.useState(!1),g=b=>l.spreads.find(M=>M.pages.some(z=>z.index===b.firstPage-1)),v=l.layouts.find(b=>b.name!=null&&b.name===o)??null;return h.jsxs(_n,{title:c("sizes"),actions:h.jsx(Ge,{icon:Dn,label:c("newSize"),disabled:f,onClick:()=>y(!0),"data-testid":"layout-new-size"}),testId:"layout-sizes",children:[h.jsx("div",{"data-testid":"layout-size-list","data-count":l.layouts.length,children:l.layouts.map(b=>{const M=b.name??c("originalSize");return h.jsxs("button",{type:"button",className:"layout-list-item layout-size-row","data-active":b.name!=null&&b.name===o,onClick:()=>{d(b.name);const z=g(b);z&&s(z)},"data-testid":`layout-size-${b.name??"original"}`,children:[h.jsx("span",{className:"layout-row-text",children:M}),h.jsx("span",{className:"kui-muted layout-count",children:c("sizeOf",{width:zu(b.width),height:zu(b.height)})})]},b.name??"")})}),h.jsx(hi,{end:h.jsx(Ge,{icon:Hn,label:c("deleteSize"),disabled:f||!v,onClick:()=>(v==null?void 0:v.name)&&void u("layout.deleteAlternate",{name:v.name}).then(()=>d(null)),"data-testid":"layout-delete-size"})}),p?h.jsx(Hj,{info:l,onClose:()=>y(!1),onMade:d}):null]})}function Hj({info:l,onClose:s,onMade:u}){const{run:c,t:f}=Ne(),o=new Set(l.layouts.map(G=>G.name).filter(G=>G!=null)),d=l.layouts[0],p=z1.find(G=>!d||Su(d.width,d.height)!==G.id)??z1[0],[y,g]=w.useState(p.width),[v,b]=w.useState(p.height),M=Su(y,v),z=G=>{const J=G==="custom"?f("sizeOf",{width:zu(y),height:zu(v)}):f(`preset.${G}`);let $=J;for(let le=2;o.has($);le+=1)$=`${J} ${le}`;return $},[x,E]=w.useState(null),T=x??z(M),C=T.trim()!==""&&!o.has(T.trim()),N=async()=>{C&&(await c("layout.createAlternate",{name:T.trim(),width:y,height:v}),u(T.trim()),s())};return h.jsxs(Un,{title:f("newSize"),onClose:s,testId:"layout-size-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:s,children:f("cancel")}),h.jsx(ua,{variant:"primary",disabled:!C,onClick:()=>void N(),"data-testid":"layout-size-ok",children:f("ok")})]}),children:[h.jsx("div",{className:"layout-presets",role:"radiogroup","aria-label":f("presets"),children:z1.map(G=>h.jsxs("button",{type:"button",role:"radio","aria-checked":M===G.id,className:"layout-preset","data-active":M===G.id,onClick:()=>{g(G.width),b(G.height)},"data-testid":`layout-size-preset-${G.id}`,children:[h.jsx("span",{className:"layout-preset-shape",style:{aspectRatio:`${G.width} / ${G.height}`},"aria-hidden":"true"}),h.jsx("span",{children:f(`preset.${G.id}`)}),h.jsx("span",{className:"kui-muted",children:`${G.width} × ${G.height} px`})]},G.id))}),h.jsxs("div",{className:"layout-grid",children:[h.jsx(xa,{label:f("width"),value:y,min:1,max:15552,step:1,unit:"px",onChange:(G,J)=>J&&g(G),testId:"layout-size-width"}),h.jsx(xa,{label:f("height"),value:v,min:1,max:15552,step:1,unit:"px",onChange:(G,J)=>J&&b(G),testId:"layout-size-height"})]}),h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:f("sizeName")}),h.jsx("input",{className:"kui-field",value:T,onChange:G=>E(G.target.value),"data-testid":"layout-size-name"})]}),o.has(T.trim())?h.jsx("p",{className:"kui-muted layout-note",children:f("sizeNameTaken")}):h.jsx("p",{className:"kui-muted layout-note",children:f("sizeNote")})]})}const Q1=new Set(["[No Paragraph Style]","[Basic Paragraph]","[None]"]);function o5({info:l,kind:s}){const{run:u,phrase:c,t:f}=Ne(),o=ml(),d=s==="paragraph"?l.paragraphStyles:l.characterStyles,p=Ln("type.selectionAttrs",{},`${l.selection.join(",")}:${l.editingText}`),y=s==="paragraph"?p==null?void 0:p.paragraphStyle:p==null?void 0:p.characterStyle,[g,v]=w.useState(null),[b,M]=w.useState(null),z=s==="paragraph"?"layout-paragraph-style":"layout-character-style",x=C=>{v(C),o||u(s==="paragraph"?"style.paragraph.apply":"style.character.apply",{name:C})},E=async()=>{const C=f(s==="paragraph"?"newParagraphStyleName":"newCharacterStyleName");let N=C;for(let G=2;d.includes(N);G+=1)N=`${C} ${G}`;if(s==="paragraph")await u("style.paragraph.create",{name:N,fromSelection:l.editingText||l.selection.length>0});else{const G=(p==null?void 0:p.chars)??{},J=Object.fromEntries(["fontFamily","fontStyle","size","fill","tracking"].filter($=>G[$]!=null).map($=>[$,G[$]]));await u("style.character.create",{name:N,chars:J})}v(N)},T=g&&d.includes(g)?g:null;return h.jsxs(_n,{title:c(s==="paragraph"?"Paragraph Styles":"Character Styles"),defaultOpen:!1,testId:`${z}s`,children:[d.map(C=>h.jsx("button",{type:"button",className:"layout-list-item","data-active":C===T,"data-current":C===y,onClick:()=>x(C),onDoubleClick:()=>M(C),"data-testid":`${z}-${C}`,children:C},C)),h.jsx(hi,{end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:Dn,label:f(s==="paragraph"?"newParagraphStyle":"newCharacterStyle"),disabled:o,onClick:()=>void E(),"data-testid":`${z}-new`}),h.jsx(Ge,{icon:Ms,label:f("editStyle"),disabled:o||!T,onClick:()=>T&&M(T),"data-testid":`${z}-edit`}),h.jsx(Ge,{icon:Hn,label:f("deleteStyle"),disabled:!T||Q1.has(T),onClick:()=>T&&void u(s==="paragraph"?"style.paragraph.delete":"style.character.delete",{name:T}).then(()=>v(null)),"data-testid":`${z}-delete`})]})}),b?h.jsx(Uj,{info:l,kind:s,name:b,onClose:()=>M(null)}):null]})}const _j=["","left","center","right","justify"];function Uj({info:l,kind:s,name:u,onClose:c}){const{run:f,t:o,phrase:d,session:p}=Ne(),y=Ln("font.families",{},p.doc?"families":null)??[],[g,v]=w.useState(u),[b,M]=w.useState(""),[z,x]=w.useState(""),[E,T]=w.useState(""),[C,N]=w.useState(""),[G,J]=w.useState(""),[$,le]=w.useState(""),Z=ae=>ae.trim()===""||!Number.isFinite(Number(ae))?void 0:Number(ae),ie=async()=>{const ae={};b&&(ae.fontFamily=b),Z(z)!=null&&(ae.size=Z(z)),Z(E)!=null&&(ae.leading={kind:"points",value:Z(E)}),Z(C)!=null&&(ae.tracking=Z(C)),G&&(ae.fill=G);const de={name:u,chars:ae};g.trim()&&g.trim()!==u&&!Q1.has(u)&&(de.rename=g.trim()),s==="paragraph"&&$&&(de.para={align:$}),await f(s==="paragraph"?"style.paragraph.edit":"style.character.edit",de),c()},se=(ae,de,q,ue)=>h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:ae}),h.jsx("input",{className:"kui-field",inputMode:"decimal",value:de,placeholder:o("unchanged"),onChange:we=>q(we.target.value),"data-testid":ue})]});return h.jsxs(Un,{title:o("styleOptions",{name:u}),onClose:c,testId:"layout-style-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:c,children:o("cancel")}),h.jsx(ua,{variant:"primary",onClick:()=>void ie(),"data-testid":"layout-style-ok",children:o("ok")})]}),children:[h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:o("styleName")}),h.jsx("input",{className:"kui-field",value:g,disabled:Q1.has(u),onChange:ae=>v(ae.target.value),"data-testid":"layout-style-name"})]}),h.jsx(Da,{label:d("Font"),value:b,choices:[["",o("unchanged")],...y.map(ae=>[ae,ae])],onChange:M,testId:"layout-style-font"}),se(o("fontSize"),z,x,"layout-style-size"),se(o("leading"),E,T,"layout-style-leading"),se(o("tracking"),C,N,"layout-style-tracking"),h.jsx(Da,{label:d("Fill"),value:G,choices:[["",o("unchanged")],...l.swatches.map(ae=>[ae,ae])],onChange:J,testId:"layout-style-fill"}),s==="paragraph"?h.jsx(Da,{label:o("alignment"),value:$,choices:_j.map(ae=>[ae,o(ae?`align.${ae}`:"unchanged")]),onChange:le,testId:"layout-style-align"}):null]})}function Bj({info:l}){const{run:s,phrase:u,t:c}=Ne(),f=ml(),[o,d]=w.useState("fill"),[p,y]=w.useState(100),[g,v]=w.useState(null),[b,M]=w.useState(!1),z=E=>{v(E.name),!(f||!l.selection.length&&!l.editingText)&&(l.editingText?s("type.char",{attrs:o==="fill"?{fill:E.name}:{stroke:E.name}}):o==="fill"?s("object.fill",{swatch:E.name,tint:p/100,ids:l.selection}):s("object.stroke",{swatch:E.name,tint:p/100,ids:l.selection}))},x=l.swatchColors.find(E=>E.name===g&&!E.locked&&E.kind!=="none"&&E.kind!=="paper"&&E.kind!=="registration");return h.jsxs(_n,{title:u("Swatches"),defaultOpen:!1,testId:"layout-swatches",children:[h.jsxs("div",{className:"layout-bar",children:[h.jsx(hg,{label:c("swatchTarget"),value:o,segments:[{value:"fill",icon:Ss,label:u("Fill")},{value:"stroke",icon:R1,label:u("Stroke")}],onChange:d,testId:"layout-swatch-target"}),h.jsx(xa,{label:c("tint"),value:p,min:0,max:100,step:1,unit:"%",width:64,onChange:E=>y(E),testId:"layout-swatch-tint"})]}),l.swatchColors.map(E=>h.jsxs("button",{type:"button",className:"layout-list-item layout-swatch-row","data-active":E.name===g,onClick:()=>z(E),"data-testid":`layout-swatch-${E.name}`,children:[h.jsx("span",{className:"layout-chip","data-kind":E.kind,style:E.color?{background:E.color}:void 0,"aria-hidden":"true"}),h.jsx("span",{className:"layout-row-text",children:E.name})]},E.name)),h.jsx(hi,{end:h.jsxs(h.Fragment,{children:[h.jsx(Ge,{icon:Dn,label:c("newSwatch"),disabled:f,onClick:()=>M(!0),"data-testid":"layout-new-swatch"}),h.jsx(Ge,{icon:Hn,label:c("deleteSwatch"),disabled:f||!x,onClick:()=>x&&void s("swatch.delete",{name:x.name}).then(()=>v(null)),"data-testid":"layout-delete-swatch"})]})}),b?h.jsx(Vj,{onClose:()=>M(!1)}):null]})}function Vj({onClose:l}){const{run:s,t:u}=Ne(),[c,f]=w.useState(""),[o,d]=w.useState("#5645d4"),p=/^#[0-9a-f]{6}$/i.test(o),y=async()=>{p&&(await s("swatch.create",c.trim()?{name:c.trim(),color:o}:{color:o}),l())};return h.jsxs(Un,{title:u("newSwatch"),onClose:l,testId:"layout-new-swatch-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:l,children:u("cancel")}),h.jsx(ua,{variant:"primary",disabled:!p,onClick:()=>void y(),"data-testid":"layout-new-swatch-ok",children:u("ok")})]}),children:[h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:u("swatchName")}),h.jsx("input",{className:"kui-field",value:c,placeholder:u("swatchNameHint"),onChange:g=>f(g.target.value),"data-testid":"layout-new-swatch-name"})]}),h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:u("swatchColor")}),h.jsxs("span",{className:"layout-color",children:[h.jsx("input",{type:"color",value:p?o:"#000000",onChange:g=>d(g.target.value),"aria-label":u("swatchColor")}),h.jsx("input",{className:"kui-field",value:o,onChange:g=>d(g.target.value.trim()),"data-testid":"layout-new-swatch-color"})]})]})]})}function qj({info:l,spread:s,onShow:u,onSetup:c}){return h.jsx("aside",{className:"kui-panel layout-side","data-side":"right","data-testid":"layout-side",children:h.jsxs("div",{className:"kui-panel-body",children:[h.jsx(Aj,{info:l}),h.jsx(Ej,{info:l,onShow:u,onSetup:c}),h.jsx(Dj,{info:l,onShow:u}),h.jsx(xj,{info:l,spread:s}),h.jsx(Bj,{info:l}),h.jsx(o5,{info:l,kind:"paragraph"}),h.jsx(o5,{info:l,kind:"character"}),h.jsx(Sj,{info:l})]})})}const fl=18,x1=[1,2,5,10,20,25,50,100,200,250,500,1e3,2e3,5e3,1e4],Gj=56;function f5(l){return x1.find(s=>s*l>=Gj)??x1[x1.length-1]}function Ig(l,s){const u=s.x+s.width/2/s.zoom,c=s.y+s.height/2/s.zoom,f=$g(l,u,c);if(!f)return null;const o=u-f.area.x0+f.left,d=f.pages.find(p=>o>=p.bounds[0]&&o<=p.bounds[2])??f.pages[0];return{x:f.area.x0+(d?d.bounds[0]:f.left)-f.left,y:f.area.y0,spread:f}}function C1(l,s){const[u,c]=w.useState(s);return w.useEffect(()=>{const f=getComputedStyle(document.documentElement).getPropertyValue(l).trim();f&&c(f)},[l]),u}function d5({axis:l,info:s,view:u,onGuide:c}){const f=w.useRef(null),[o,d]=w.useState({width:0,height:0}),p=C1("--kit-text-muted","#6b6b76"),y=C1("--kit-border","#d9d9e0"),g=C1("--kit-surface","#ffffff"),v=u?Ig(s,u):null,b=u&&v?l==="x"?(v.x-u.x)*u.zoom:(v.y-u.y)*u.zoom:0;w.useEffect(()=>{const z=f.current;if(!z||typeof ResizeObserver>"u")return;const x=new ResizeObserver(([E])=>d({width:E.contentRect.width,height:E.contentRect.height}));return x.observe(z),()=>x.disconnect()},[]),w.useEffect(()=>{const z=f.current,x=z==null?void 0:z.getContext("2d");if(!z||!x||!u||!o.width||!o.height)return;const E=window.devicePixelRatio||1;z.width=Math.round(o.width*E),z.height=Math.round(o.height*E),x.setTransform(E,0,0,E,0,0),x.fillStyle=g,x.fillRect(0,0,o.width,o.height),x.strokeStyle=y,x.fillStyle=p,x.lineWidth=1,x.font="9px system-ui, sans-serif",x.beginPath(),l==="x"?(x.moveTo(0,o.height-.5),x.lineTo(o.width,o.height-.5)):(x.moveTo(o.width-.5,0),x.lineTo(o.width-.5,o.height));const T=l==="x"?o.width:o.height,C=f5(u.zoom),N=C/5,G=Math.floor(-b/u.zoom/N)*N;for(let J=G;J*u.zoom+b<=T;J+=N){const $=Math.round(J*u.zoom+b)+.5,le=Math.abs(J/C-Math.round(J/C))<1e-6,Z=le?fl:fl*.3;l==="x"?(x.moveTo($,fl-Z),x.lineTo($,fl),le&&x.fillText(String(Math.round(J)),$+2,9)):(x.moveTo(fl-Z,$),x.lineTo(fl,$),le&&(x.save(),x.translate(9,$+2),x.rotate(-Math.PI/2),x.textAlign="right",x.fillText(String(Math.round(J)),0,0),x.restore()))}x.stroke()},[b,l,y,o,g,p,u]);const M=z=>{if(z.button!==0||!u)return;const x=z.currentTarget.getBoundingClientRect(),E=T=>{window.removeEventListener("pointerup",E);const C=l==="x"?x.left:x.right,N=l==="x"?x.bottom:x.top,G=(T.clientX-C)/u.zoom,J=(T.clientY-N)/u.zoom;if(l==="x"&&J<=0||l==="y"&&G<=0)return;const $=u.x+G,le=u.y+J,Z=$g(s,$,le);Z&&(l==="x"?c("horizontal",le-Z.area.y0,Z.index):c("vertical",$-Z.area.x0+Z.left,Z.index))};window.addEventListener("pointerup",E)};return h.jsx("canvas",{ref:f,className:"layout-ruler","data-axis":l,"data-origin":Math.round(b*100)/100,"data-zoom":u==null?void 0:u.zoom,"data-step":u?f5(u.zoom):void 0,onPointerDown:M,"data-testid":`layout-ruler-${l}`})}const Zg=["png","jpeg","pdf","idml","epub","html"],Fg={png:"png",jpeg:"jpg",pdf:"pdf",idml:"idml",epub:"epub",html:"html"};function Yj(l,s){const u={format:Fg[l]};return l==="pdf"&&Object.assign(u,s.pages?{pages:s.pages}:{},{bleed:s.bleed}),{command:"file.exportBytes",params:u}}function J1(l){return Uint8Array.from(atob(l),s=>s.charCodeAt(0))}function $j(l){return l?typeof l.data=="string"?J1(l.data):typeof l.base64=="string"?J1(l.base64):typeof l.text=="string"?new TextEncoder().encode(l.text):null:null}function Xj(l){return l.replace(/\.[^.]+$/,"").trim()||"Untitled"}function Kj(l){return l.includes("/")?l.slice(0,l.lastIndexOf("/")+1):""}function h5(l,s,u=""){return`${Kj(l.path)}${Xj(l.name)}${u}.${Fg[s]}`}async function Ij(l,s){const u=[];for(const c of l){const f=await s(c.path,c.bytes);if(typeof f!="string"||!f)throw new Error(`the host did not write ${c.path}`);u.push(f)}return u}const Qg={format:"png",range:"all",pages:"",ppi:72,transparent:!1,quality:90,bleed:!1};function Zj(l){if(!l||typeof l!="object")return;const s={...Qg,...l};if(!(!Zg.includes(s.format)||!["all","current","range","sizes"].includes(s.range))&&!(!Number.isFinite(s.ppi)||s.ppi<1||s.ppi>2400||!Number.isFinite(s.quality)))return s}const Fj=l=>l.replace(/[\\/:*?"<>|]+/g,"-").trim()||"size";function Qj({info:l,page:s,onClose:u}){const{query:c,host:f,t:o}=Ne(),d=`export:${f.init.document.path}`,[p,y]=db("kit.layout",d,{initial:Qg,validate:Zj}),[g,v]=w.useState(p),[b,M]=w.useState(!1),z=$=>v(le=>({...le,...$})),x=g.format==="png"||g.format==="jpeg",E=x||g.format==="pdf",T=g.range==="sizes"&&l.layouts.length>1&&x,C=g.range==="sizes"&&!T?"all":g.range,N=C==="all"||T?void 0:C==="current"?String(s+1):g.pages.trim()||void 0,G={name:f.init.document.name||"Untitled",path:f.init.document.path},J=async()=>{M(!0),y(g);try{const $=[];if(x){const Z=await c("file.exportImage",{format:g.format,...N?{pages:N}:{},...T?{sizes:!0}:{},ppi:g.ppi,background:g.format==="png"&&g.transparent?"transparent":"paper",quality:g.quality,bleed:g.bleed});if(!Z)throw new Error(o("exportFailed"));const ie=Z.files.length>1,se=ae=>Z.files.filter(de=>de.layout===ae).length;for(const ae of Z.files){const de=l.layouts.length>1&&ae.layout!=null,q=de?se(ae.layout)>1:ie&&(l.layouts.length<2||se(null)>1),ue=`${de?`-${Fj(ae.layout??"")}`:""}${q?`-${ae.page}`:""}`;$.push({path:h5(G,g.format,ue),bytes:J1(ae.base64)})}}else{const Z=Yj(g.format,{pages:N,bleed:g.bleed}),ie=$j(await c(Z.command,Z.params));if(!ie)throw new Error(o("exportFailed"));$.push({path:h5(G,g.format),bytes:ie})}const le=await Ij($,(Z,ie)=>f.exportFile(Z,ie));ui("success",o("exported",{count:le.length}),le.map(Z=>Z.split("/").pop()).join(", ")),u()}catch($){ui("error",o("exportFailed"),$ instanceof Error?$.message:String($))}finally{M(!1)}};return h.jsx(Un,{title:o("export"),onClose:u,testId:"layout-export-dialog",actions:h.jsxs(h.Fragment,{children:[h.jsx(ua,{onClick:u,children:o("cancel")}),h.jsx(ua,{variant:"primary",disabled:b,onClick:()=>void J(),"data-testid":"layout-export-ok",children:o("exportAction")})]}),children:h.jsxs("div",{className:"layout-dialog-stack",children:[h.jsx(Da,{label:o("format"),value:g.format,choices:Zg.map($=>[$,o(`format.${$}`)]),onChange:$=>z({format:$}),testId:"layout-export-format"}),E?h.jsxs(h.Fragment,{children:[h.jsx(Da,{label:o("pages"),value:C,choices:[["all",o("allPages",{count:l.pageCount})],...x&&l.layouts.length>1?[["sizes",o("allSizes",{count:l.layouts.length})]]:[],["current",o("currentPage",{page:s+1})],["range",o("pageRange")]],onChange:$=>z({range:$}),testId:"layout-export-range"}),C==="range"?h.jsxs("label",{className:"layout-field",children:[h.jsx("span",{children:o("pageRange")}),h.jsx("input",{className:"kui-field",value:g.pages,placeholder:"1-3, 5",onChange:$=>z({pages:$.target.value}),"data-testid":"layout-export-pages"})]}):null,h.jsx(H1,{label:o("includeBleed"),checked:g.bleed,onChange:$=>z({bleed:$}),testId:"layout-export-bleed"})]}):null,x?h.jsxs(h.Fragment,{children:[h.jsx(Da,{label:o("resolution"),value:String(g.ppi),choices:[72,144,216,300].map($=>[String($),o("scale",{scale:$/72,ppi:$})]),onChange:$=>z({ppi:Number($)}),testId:"layout-export-ppi"}),g.format==="png"?h.jsx(H1,{label:o("transparentBackground"),checked:g.transparent,onChange:$=>z({transparent:$}),testId:"layout-export-transparent"}):null,g.format==="jpeg"?h.jsx(xa,{label:o("quality"),value:g.quality,min:1,max:100,step:1,track:!0,onChange:($,le)=>le&&z({quality:$}),testId:"layout-export-quality"}):null]}):null]})})}const Jj=l=>new URL(`./templates/${l}.png`,document.baseURI).href;function Pj({onClose:l}){const{run:s,t:u}=Ne(),c=Ln("template.list",{},"templates")??[],f=async o=>{await s("document.applyTemplate",{template:o}),l()};return h.jsxs(Un,{title:u("templates"),onClose:l,testId:"layout-templates-dialog",actions:h.jsx(ua,{onClick:l,children:u("cancel")}),children:[h.jsx("div",{className:"layout-templates",role:"list",children:c.map(o=>h.jsxs("button",{type:"button",role:"listitem",className:"layout-template",onClick:()=>void f(o.id),"data-testid":`layout-template-${o.id}`,children:[h.jsx("img",{className:"layout-template-preview",src:Jj(o.id),alt:"",style:{aspectRatio:`${o.width} / ${o.height}`}}),h.jsx("span",{children:u(`template.${o.id}`)}),h.jsx("span",{className:"kui-muted",children:`${o.width} × ${o.height} px`})]},o.id))}),h.jsx("p",{className:"kui-muted layout-note",children:u("templatesNote")})]})}const Wj={hand:Dt,zoom:gk},eN=new Set(Kg),aN=["file.new","book.new","library.new","file.open","file.close","file.save","file.saveAs","file.revert"],tN=["document.applyTemplate","layout.documentSetup","file.exportPdf","file.exportEpub","file.exportFixedEpub","file.exportHtml"],nN=["View","Window","Help"];function lN({host:l,phrase:s}){var Z,ie;const u=w.useMemo(()=>Lg(Yg,l.init.locale),[l]),c=w.useMemo(hj,[]),f=bA(l,c,gj),o=Gk(f,l,u,"layout",s),{doc:d,change:p,state:y}=f,g=lj(f.tool,d!=null,p,{initial:"selection",hostTools:Wj,hidden:eN}),v=w.useRef(null);fj(d,v);const b=w.useRef(null),[M,z]=w.useState(null),[x,E]=w.useState(null),T=(M==null?void 0:M.zoom)??1,C=y&&M?Ig(y,M):null,N=(C==null?void 0:C.spread)??(y==null?void 0:y.spreads[0])??null,G=C?((Z=C.spread.pages.find(se=>C.spread.area.x0+se.bounds[0]-C.spread.left===C.x))==null?void 0:Z.index)??0:0,{commands:J}=o,$=(se,ae,de)=>{l.readOnly||o.run("guide.add",{orientation:se,position:ae,spread:de})},le=w.useMemo(()=>[{id:"home",label:u("homeTab"),ribbon:h.jsx(zj,{onDialog:E})},...DA(J,{order:bj,exclude:[...aN,...tN],phrase:s,view:nN,primary:wj,before:{File:[{label:u("templatesMenu"),onSelect:()=>E("templates"),testId:"layout-menu-templates",primary:!0},{label:u("documentSetupMenu"),onSelect:()=>E("setup"),testId:"layout-menu-document-setup",primary:!0},{label:u("exportMenu"),onSelect:()=>E("export"),testId:"layout-menu-export",primary:!0}]}})],[J,s,u]);return h.jsx(Yk,{editor:o,tools:g,children:h.jsxs(JA,{tabs:le,defaultTab:"home",canvas:v,zoom:T,onKeyDown:se=>se.key!=="Escape"||se.metaKey||se.ctrlKey||se.altKey||se.shiftKey||!(y!=null&&y.selected)?!1:(o.run("selection.set",{ids:[]}),!0),status:h.jsxs(h.Fragment,{children:[h.jsx("span",{"data-testid":"layout-status",children:g.status?s(g.status):y?u(y.pageCount===1?"summaryOne":"summary",{pages:y.pageCount}):""}),y!=null&&y.selected?h.jsx("span",{children:u("selectedCount",{count:y.selected})}):null]}),rail:h.jsx(uA,{hidden:Kg}),panels:y?h.jsx(qj,{info:y,spread:N,onShow:se=>{var ae;return(ae=v.current)==null?void 0:ae.show(se.area)},onSetup:()=>E("setup")}):null,children:[h.jsx("div",{className:"kui-row","data-testid":"layout-workspace","data-view":M?`${M.zoom} ${M.x} ${M.y}`:void 0,children:h.jsx(iN,{rulers:h.jsxs(h.Fragment,{children:[h.jsx("span",{className:"layout-ruler-corner","aria-hidden":"true"}),y?h.jsx(d5,{axis:"x",info:y,view:M,onGuide:$}):h.jsx("span",{}),y?h.jsx(d5,{axis:"y",info:y,view:M,onGuide:$}):h.jsx("span",{})]}),children:h.jsx(Kk,{canvas:v,viewMemory:b,initialArea:((ie=y==null?void 0:y.spreads[0])==null?void 0:ie.area)??null,framed:!1,onView:z})})}),y&&x==="setup"?h.jsx(Lj,{info:y,onClose:()=>E(null)}):null,y&&x==="export"?h.jsx(Qj,{info:y,page:G,onClose:()=>E(null)}):null,y&&x==="templates"?h.jsx(Pj,{onClose:()=>E(null)}):null]})})}function iN({rulers:l,children:s}){const u=VA()==="focus",c=u?"minmax(0, 1fr)":`${fl}px minmax(0, 1fr)`;return h.jsxs("div",{className:"layout-canvas-frame",style:{gridTemplateColumns:c,gridTemplateRows:c},children:[u?null:l,s]})}const sN={display:"line",brand:{light:"#d32f8d",dark:"#f57bbd"}},m5={ui:sN},Jg=fb.createRoot(document.getElementById("root")),rN=window.setTimeout(()=>{const l=Lg(Yg,navigator.language);Jg.render(h.jsx("div",{className:"kui-alone",children:l("noHost")}))},3e3);BT({id:"kit.layout",version:"0.1.4",capabilities:["ai","replica"],brand:m5.ui.brand,display:m5.ui.display}).then(async l=>{window.clearTimeout(rN);const s=oj(await cj({},l.init.locale),pj,l.init.locale);Jg.render(h.jsx(lN,{host:l,phrase:s}))});