@myoc/excalidraw 0.18.14 → 0.18.15

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.
@@ -4,7 +4,7 @@ import {
4
4
  subsetToBinary,
5
5
  toBase64
6
6
  } from "./chunk-FB2NA5UG.js";
7
- import "./chunk-4MUT22YZ.js";
7
+ import "./chunk-DJKQZ4KD.js";
8
8
  import "./chunk-XDFCUUT6.js";
9
9
  export {
10
10
  Commands,
@@ -2,7 +2,7 @@ import {
2
2
  Commands,
3
3
  subsetToBinary
4
4
  } from "./chunk-FB2NA5UG.js";
5
- import "./chunk-4MUT22YZ.js";
5
+ import "./chunk-DJKQZ4KD.js";
6
6
  import "./chunk-XDFCUUT6.js";
7
7
 
8
8
  // subset/subset-worker.chunk.ts
@@ -4,4 +4,4 @@ kPOPxhz+nxUrIoWCD/V4NGmUA1lxwHuO21HN1gzKrN3xHg5EGjyouR9vibT9VDGF
4
4
  gq6+4Ic/kJX+AD2MM7Yre2+FsOdysrmuW2Fu3ahuC1uQE7pOe1j0k7auNP0y1q53
5
5
  PrB8Ts2LUpepWC1l7zIXFm4ViDULuyWXTEpUcHSsEH8vpd1tckjypxCwkipfZsXx
6
6
  iPszy0o0Dx2iArPfWMXlFAI9mvyFCyFC3+nSvfyAUb2C4uZgCwAuyFh/ydPF4DEE
7
- PQIDAQAB`,VITE_APP_DEBUG_ENABLE_TEXT_CONTAINER_BOUNDING_BOX:"false",VITE_APP_COLLAPSE_OVERLAY:"false",VITE_APP_ENABLE_ESLINT:"false",PKG_NAME:"@myoc/excalidraw",PKG_VERSION:"0.18.13",PROD:!0};export{c as a};
7
+ PQIDAQAB`,VITE_APP_DEBUG_ENABLE_TEXT_CONTAINER_BOUNDING_BOX:"false",VITE_APP_COLLAPSE_OVERLAY:"false",VITE_APP_ENABLE_ESLINT:"false",PKG_NAME:"@myoc/excalidraw",PKG_VERSION:"0.18.14",PROD:!0};export{c as a};
@@ -1,4 +1,4 @@
1
- import{a as $}from"./chunk-5P7BZ5EW.js";import{d as N}from"./chunk-SRAX5OIU.js";import e6 from"png-chunk-text";import Hu from"png-chunks-encode";import t6 from"png-chunks-extract";var dr=class{constructor(t){this.scoreFunction=t;N(this,"content",[])}sinkDown(t){let n=this.content[t];for(;t>0;){let r=(t+1>>1)-1,o=this.content[r];if(this.scoreFunction(n)<this.scoreFunction(o))this.content[r]=n,this.content[t]=o,t=r;else break}}bubbleUp(t){let n=this.content.length,r=this.content[t],o=this.scoreFunction(r);for(;;){let i=t+1<<1,a=i-1,s=null,d=0;if(a<n){let U=this.content[a];d=this.scoreFunction(U),d<o&&(s=a)}if(i<n){let U=this.content[i];this.scoreFunction(U)<(s===null?o:d)&&(s=i)}if(s!==null)this.content[t]=this.content[s],this.content[s]=r,t=s;else break}}push(t){this.content.push(t),this.sinkDown(this.content.length-1)}pop(){if(this.content.length===0)return null;let t=this.content[0],n=this.content.pop();return this.content.length>0&&(this.content[0]=n,this.bubbleUp(0)),t}remove(t){if(this.content.length===0)return;let n=this.content.indexOf(t),r=this.content.pop();n<this.content.length&&(this.content[n]=r,this.scoreFunction(r)<this.scoreFunction(t)?this.sinkDown(n):this.bubbleUp(n))}size(){return this.content.length}rescoreElement(t){this.sinkDown(this.content.indexOf(t))}};import n6 from"open-color";var Xu=240,r6=(e,t)=>t.reduce((n,r)=>(r in e&&(n[r]=e[r]),n),{}),Gu=5,Zu=5,ku=4,cr=4,Ur=1,et=[0,2,4,6,8];var tt=(e,t)=>t.map(n=>n6[e][n]),V={transparent:"transparent",black:"#1e1e1e",white:"#ffffff",gray:tt("gray",et),red:tt("red",et),pink:tt("pink",et),grape:tt("grape",et),violet:tt("violet",et),blue:tt("blue",et),cyan:tt("cyan",et),teal:tt("teal",et),green:tt("green",et),yellow:tt("yellow",et),orange:tt("orange",et),bronze:["#f8f1ee","#eaddd7","#d2bab0","#a18072","#846358"]},na=r6(V,["cyan","blue","violet","grape","pink","green","teal","yellow","orange","red"]),Wu=[V.black,V.red[cr],V.green[cr],V.blue[cr],V.yellow[cr]],Qu=[V.transparent,V.red[Ur],V.green[Ur],V.blue[Ur],V.yellow[Ur]],zu=[V.white,"#f8f9fa","#f5faff","#fffce8","#fdf8f6"],ju={transparent:V.transparent,white:V.white,gray:V.gray,black:V.black,bronze:V.bronze,...na},e9={transparent:V.transparent,white:V.white,gray:V.gray,black:V.black,bronze:V.bronze,...na},t9=e=>[V.cyan[e],V.blue[e],V.violet[e],V.grape[e],V.pink[e],V.green[e],V.teal[e],V.yellow[e],V.orange[e],V.red[e]],n9=(e,t,n)=>`#${((1<<24)+(e<<16)+(t<<8)+n).toString(16).slice(1)}`;var lr=/Mac|iPod|iPhone|iPad/.test(navigator.platform),a9=/^Win/.test(navigator.platform),s9=/\b(android)\b/i.test(navigator.userAgent),d9="netscape"in window&&navigator.userAgent.indexOf("rv:")>1&&navigator.userAgent.indexOf("Gecko")>1,o6=navigator.userAgent.indexOf("Chrome")!==-1,c9=!o6&&navigator.userAgent.indexOf("Safari")!==-1,U9=/iPad|iPhone/.test(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document,l9=()=>navigator.brave?.isBrave?.name==="isBrave",f9=typeof window<"u"&&"ResizeObserver"in window,p9="Excalidraw",u9=36,ra=10,oa=8,b9=5,E9=1,m9=30,Fn=Math.PI/12,g9="red",x9={TEXT:"text",CROSSHAIR:"crosshair",GRABBING:"grabbing",GRAB:"grab",POINTER:"pointer",MOVE:"move",AUTO:""},h9={MAIN:0,WHEEL:1,SECONDARY:2,TOUCH:-1,ERASER:5},y9={enabled:"all",disabled:"none",inheritFromUI:"var(--ui-pointerEvents)"};var I9={UNSTARTED:-1,ENDED:0,PLAYING:1,PAUSED:2,BUFFERING:3,CUED:5},fr={TEST:"test",DEVELOPMENT:"development",PRODUCTION:"production"},w9={SHAPE_ACTIONS_MENU:"App-menu__left",ZOOM_ACTIONS:"zoom-actions",SEARCH_MENU_INPUT_WRAPPER:"layer-ui__search-inputWrapper"},kt="Xiaolai",Zt="Segoe UI Emoji",pe={Virgil:1,Helvetica:2,Cascadia:3,Excalifont:5,Nunito:6,"Lilita One":7,"Comic Shanns":8,"Liberation Sans":9},Ft={[kt]:100,[Zt]:1e3},pr=e=>{switch(e){case pe.Excalifont:return[kt,Zt];default:return[Zt]}},Xe={LIGHT:"light",DARK:"dark"},we={strokeColor:"#bbb",strokeWidth:2,strokeStyle:"solid",fillStyle:"solid",roughness:0,roundness:null,backgroundColor:"transparent",radius:8,nameOffsetY:3,nameColorLightTheme:"#999999",nameColorDarkTheme:"#7a7a7a",nameFontSize:14,nameLineHeight:1.25},R9=1,St=20,Pt=pe.Excalifont,ln="left",ur="top";var i6=2,a6=2*i6,s6=1e-5,T9=2*a6-s6,L9="#ffffff",M9="#1e1e1e",$9="#a2f1a6";var br=20,Er=5,mr={svg:"image/svg+xml",png:"image/png",jpg:"image/jpeg",gif:"image/gif",webp:"image/webp",bmp:"image/bmp",ico:"image/x-icon",avif:"image/avif",jfif:"image/jfif"},C={text:"text/plain",html:"text/html",json:"application/json",excalidraw:"application/vnd.excalidraw+json",excalidrawlib:"application/vnd.excalidrawlib+json","excalidraw.svg":"image/svg+xml","excalidraw.png":"image/png",binary:"application/octet-stream",...mr},D9=[C.text,C.html,...Object.values(mr)],v9={png:"png",svg:"svg",clipboard:"clipboard"},gt={excalidraw:"excalidraw",excalidrawClipboard:"excalidraw/clipboard",excalidrawLibrary:"excalidrawlib",excalidrawClipboardWithAPI:"excalidraw-api/clipboard"},Mo=window.EXCALIDRAW_EXPORT_SOURCE||window.location.origin,N9=500,F9=300,S9=500;var P9=100,_9=.1,ia=.1,aa=30,B9=300;var gr="invert(93%) hue-rotate(180deg)",O9={addLibrary:"addLibrary"},K9={addLibrary:"addLibrary"},J9={canvasActions:{changeViewBackgroundColor:!0,export:{saveFileToDisk:!0},loadScene:!0,saveToActiveFile:!0,toggleTheme:null,saveAsImage:!0},tools:{image:!0}},H9=730,Y9=1e3,A9=500,V9=1229,fn=2,sa=[1,2,3],$o=10,q9=1440,C9=100*1024*1024,k="http://www.w3.org/2000/svg",X9=`<?xml version="1.0" standalone="no"?>
1
+ import{a as $}from"./chunk-NJOW7IOK.js";import{d as N}from"./chunk-SRAX5OIU.js";import e6 from"png-chunk-text";import Hu from"png-chunks-encode";import t6 from"png-chunks-extract";var dr=class{constructor(t){this.scoreFunction=t;N(this,"content",[])}sinkDown(t){let n=this.content[t];for(;t>0;){let r=(t+1>>1)-1,o=this.content[r];if(this.scoreFunction(n)<this.scoreFunction(o))this.content[r]=n,this.content[t]=o,t=r;else break}}bubbleUp(t){let n=this.content.length,r=this.content[t],o=this.scoreFunction(r);for(;;){let i=t+1<<1,a=i-1,s=null,d=0;if(a<n){let U=this.content[a];d=this.scoreFunction(U),d<o&&(s=a)}if(i<n){let U=this.content[i];this.scoreFunction(U)<(s===null?o:d)&&(s=i)}if(s!==null)this.content[t]=this.content[s],this.content[s]=r,t=s;else break}}push(t){this.content.push(t),this.sinkDown(this.content.length-1)}pop(){if(this.content.length===0)return null;let t=this.content[0],n=this.content.pop();return this.content.length>0&&(this.content[0]=n,this.bubbleUp(0)),t}remove(t){if(this.content.length===0)return;let n=this.content.indexOf(t),r=this.content.pop();n<this.content.length&&(this.content[n]=r,this.scoreFunction(r)<this.scoreFunction(t)?this.sinkDown(n):this.bubbleUp(n))}size(){return this.content.length}rescoreElement(t){this.sinkDown(this.content.indexOf(t))}};import n6 from"open-color";var Xu=240,r6=(e,t)=>t.reduce((n,r)=>(r in e&&(n[r]=e[r]),n),{}),Gu=5,Zu=5,ku=4,cr=4,Ur=1,et=[0,2,4,6,8];var tt=(e,t)=>t.map(n=>n6[e][n]),V={transparent:"transparent",black:"#1e1e1e",white:"#ffffff",gray:tt("gray",et),red:tt("red",et),pink:tt("pink",et),grape:tt("grape",et),violet:tt("violet",et),blue:tt("blue",et),cyan:tt("cyan",et),teal:tt("teal",et),green:tt("green",et),yellow:tt("yellow",et),orange:tt("orange",et),bronze:["#f8f1ee","#eaddd7","#d2bab0","#a18072","#846358"]},na=r6(V,["cyan","blue","violet","grape","pink","green","teal","yellow","orange","red"]),Wu=[V.black,V.red[cr],V.green[cr],V.blue[cr],V.yellow[cr]],Qu=[V.transparent,V.red[Ur],V.green[Ur],V.blue[Ur],V.yellow[Ur]],zu=[V.white,"#f8f9fa","#f5faff","#fffce8","#fdf8f6"],ju={transparent:V.transparent,white:V.white,gray:V.gray,black:V.black,bronze:V.bronze,...na},e9={transparent:V.transparent,white:V.white,gray:V.gray,black:V.black,bronze:V.bronze,...na},t9=e=>[V.cyan[e],V.blue[e],V.violet[e],V.grape[e],V.pink[e],V.green[e],V.teal[e],V.yellow[e],V.orange[e],V.red[e]],n9=(e,t,n)=>`#${((1<<24)+(e<<16)+(t<<8)+n).toString(16).slice(1)}`;var lr=/Mac|iPod|iPhone|iPad/.test(navigator.platform),a9=/^Win/.test(navigator.platform),s9=/\b(android)\b/i.test(navigator.userAgent),d9="netscape"in window&&navigator.userAgent.indexOf("rv:")>1&&navigator.userAgent.indexOf("Gecko")>1,o6=navigator.userAgent.indexOf("Chrome")!==-1,c9=!o6&&navigator.userAgent.indexOf("Safari")!==-1,U9=/iPad|iPhone/.test(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document,l9=()=>navigator.brave?.isBrave?.name==="isBrave",f9=typeof window<"u"&&"ResizeObserver"in window,p9="Excalidraw",u9=36,ra=10,oa=8,b9=5,E9=1,m9=30,Fn=Math.PI/12,g9="red",x9={TEXT:"text",CROSSHAIR:"crosshair",GRABBING:"grabbing",GRAB:"grab",POINTER:"pointer",MOVE:"move",AUTO:""},h9={MAIN:0,WHEEL:1,SECONDARY:2,TOUCH:-1,ERASER:5},y9={enabled:"all",disabled:"none",inheritFromUI:"var(--ui-pointerEvents)"};var I9={UNSTARTED:-1,ENDED:0,PLAYING:1,PAUSED:2,BUFFERING:3,CUED:5},fr={TEST:"test",DEVELOPMENT:"development",PRODUCTION:"production"},w9={SHAPE_ACTIONS_MENU:"App-menu__left",ZOOM_ACTIONS:"zoom-actions",SEARCH_MENU_INPUT_WRAPPER:"layer-ui__search-inputWrapper"},kt="Xiaolai",Zt="Segoe UI Emoji",pe={Virgil:1,Helvetica:2,Cascadia:3,Excalifont:5,Nunito:6,"Lilita One":7,"Comic Shanns":8,"Liberation Sans":9},Ft={[kt]:100,[Zt]:1e3},pr=e=>{switch(e){case pe.Excalifont:return[kt,Zt];default:return[Zt]}},Xe={LIGHT:"light",DARK:"dark"},we={strokeColor:"#bbb",strokeWidth:2,strokeStyle:"solid",fillStyle:"solid",roughness:0,roundness:null,backgroundColor:"transparent",radius:8,nameOffsetY:3,nameColorLightTheme:"#999999",nameColorDarkTheme:"#7a7a7a",nameFontSize:14,nameLineHeight:1.25},R9=1,St=20,Pt=pe.Excalifont,ln="left",ur="top";var i6=2,a6=2*i6,s6=1e-5,T9=2*a6-s6,L9="#ffffff",M9="#1e1e1e",$9="#a2f1a6";var br=20,Er=5,mr={svg:"image/svg+xml",png:"image/png",jpg:"image/jpeg",gif:"image/gif",webp:"image/webp",bmp:"image/bmp",ico:"image/x-icon",avif:"image/avif",jfif:"image/jfif"},C={text:"text/plain",html:"text/html",json:"application/json",excalidraw:"application/vnd.excalidraw+json",excalidrawlib:"application/vnd.excalidrawlib+json","excalidraw.svg":"image/svg+xml","excalidraw.png":"image/png",binary:"application/octet-stream",...mr},D9=[C.text,C.html,...Object.values(mr)],v9={png:"png",svg:"svg",clipboard:"clipboard"},gt={excalidraw:"excalidraw",excalidrawClipboard:"excalidraw/clipboard",excalidrawLibrary:"excalidrawlib",excalidrawClipboardWithAPI:"excalidraw-api/clipboard"},Mo=window.EXCALIDRAW_EXPORT_SOURCE||window.location.origin,N9=500,F9=300,S9=500;var P9=100,_9=.1,ia=.1,aa=30,B9=300;var gr="invert(93%) hue-rotate(180deg)",O9={addLibrary:"addLibrary"},K9={addLibrary:"addLibrary"},J9={canvasActions:{changeViewBackgroundColor:!0,export:{saveFileToDisk:!0},loadScene:!0,saveToActiveFile:!0,toggleTheme:null,saveAsImage:!0},tools:{image:!0}},H9=730,Y9=1e3,A9=500,V9=1229,fn=2,sa=[1,2,3],$o=10,q9=1440,C9=100*1024*1024,k="http://www.w3.org/2000/svg",X9=`<?xml version="1.0" standalone="no"?>
2
2
  <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
3
3
  `;var Do={excalidraw:2,excalidrawLibrary:2},ye=5,da=.7,ca=11,Wt={TOP:"top",MIDDLE:"middle",BOTTOM:"bottom"},vo={LEFT:"left",CENTER:"center",RIGHT:"right"},Ua=20,xr=.25,la=32,He={LEGACY:1,PROPORTIONAL_RADIUS:2,ADAPTIVE_RADIUS:3},No={architect:0,artist:1,cartoonist:2},G9={thin:1,bold:2,extraBold:4},ue={strokeColor:V.black,backgroundColor:V.transparent,fillStyle:"solid",strokeWidth:2,strokeStyle:"solid",roughness:No.artist,opacity:100,locked:!1},d6="library",Z9="search",fa={name:"default",defaultTab:d6},k9=new Set(["iframe","embeddable","image"]),W9={selection:"selection",lasso:"lasso",rectangle:"rectangle",diamond:"diamond",ellipse:"ellipse",arrow:"arrow",line:"line",freedraw:"freedraw",text:"text",image:"image",eraser:"eraser",hand:"hand",frame:"frame",magicframe:"magicframe",embeddable:"embeddable",laser:"laser"},Q9={OAI_API_KEY:"excalidraw-oai-api-key",MERMAID_TO_EXCALIDRAW:"mermaid-to-excalidraw",PUBLISH_LIBRARY:"publish-library-data"},pa="Untitled",Fo={generalStats:1,elementProperties:2},z9=1,ua={sharp:"sharp",round:"round",elbow:"elbow"},ba=.3,Sn="element",j9=Symbol.for("__test__originalId__"),c6=(r=>(r.ACTIVE="active",r.AWAY="away",r.IDLE="idle",r))(c6||{});var Qt={[pe.Excalifont]:{metrics:{unitsPerEm:1e3,ascender:886,descender:-374,lineHeight:1.25}},[pe.Nunito]:{metrics:{unitsPerEm:1e3,ascender:1011,descender:-353,lineHeight:1.35}},[pe["Lilita One"]]:{metrics:{unitsPerEm:1e3,ascender:923,descender:-220,lineHeight:1.15}},[pe["Comic Shanns"]]:{metrics:{unitsPerEm:1e3,ascender:750,descender:-250,lineHeight:1.25}},[pe.Virgil]:{metrics:{unitsPerEm:1e3,ascender:886,descender:-374,lineHeight:1.25},deprecated:!0},[pe.Helvetica]:{metrics:{unitsPerEm:2048,ascender:1577,descender:-471,lineHeight:1.15},deprecated:!0,local:!0},[pe.Cascadia]:{metrics:{unitsPerEm:2048,ascender:1900,descender:-480,lineHeight:1.2},deprecated:!0},[pe["Liberation Sans"]]:{metrics:{unitsPerEm:2048,ascender:1854,descender:-434,lineHeight:1.15},serverSide:!0},[Ft.Xiaolai]:{metrics:{unitsPerEm:1e3,ascender:880,descender:-144,lineHeight:1.15},fallback:!0},[Ft["Segoe UI Emoji"]]:{metrics:{unitsPerEm:1e3,ascender:886,descender:-374,lineHeight:1.25},local:!0,fallback:!0}},xt={LATIN:"U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD",LATIN_EXT:"U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF",CYRILIC_EXT:"U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F",CYRILIC:"U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116",VIETNAMESE:"U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB"},pn="local:",hr=(e,t,n)=>{let{unitsPerEm:r,ascender:o,descender:i}=Qt[e]?.metrics||Qt[pe.Excalifont].metrics,a=t/r,s=(n-a*o+a*i)/2;return a*o+s},yr=e=>{let{lineHeight:t}=Qt[e]?.metrics||Qt[pe.Excalifont].metrics;return t};var Ea=class{constructor(){N(this,"jobs",[]);N(this,"running",!1)}tick(){if(this.running)return;let t=this.jobs.shift();t?(this.running=!0,t.promise.resolve(ft(t.jobFactory,...t.args).finally(()=>{this.running=!1,this.tick()}))):this.running=!1}push(t,...n){let r=ma();return this.jobs.push({jobFactory:t,promise:r,args:n}),this.tick(),r}};var ga={EQUAL:"Equal",MINUS:"Minus",NUM_ADD:"NumpadAdd",NUM_SUBTRACT:"NumpadSubtract",NUM_ZERO:"Numpad0",BRACKET_RIGHT:"BracketRight",BRACKET_LEFT:"BracketLeft",ONE:"Digit1",TWO:"Digit2",THREE:"Digit3",NINE:"Digit9",QUOTE:"Quote",ZERO:"Digit0",SLASH:"Slash",C:"KeyC",D:"KeyD",H:"KeyH",V:"KeyV",Z:"KeyZ",Y:"KeyY",R:"KeyR",S:"KeyS"},le={ARROW_DOWN:"ArrowDown",ARROW_LEFT:"ArrowLeft",ARROW_RIGHT:"ArrowRight",ARROW_UP:"ArrowUp",PAGE_UP:"PageUp",PAGE_DOWN:"PageDown",BACKSPACE:"Backspace",ALT:"Alt",CTRL_OR_CMD:lr?"metaKey":"ctrlKey",DELETE:"Delete",ENTER:"Enter",ESCAPE:"Escape",QUESTION_MARK:"?",SPACE:" ",TAB:"Tab",CHEVRON_LEFT:"<",CHEVRON_RIGHT:">",PERIOD:".",COMMA:",",SUBTRACT:"-",SLASH:"/",A:"a",C:"c",D:"d",E:"e",F:"f",G:"g",H:"h",I:"i",L:"l",O:"o",P:"p",Q:"q",R:"r",S:"s",T:"t",V:"v",X:"x",Y:"y",Z:"z",K:"k",W:"w",0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},U6=new Map([[le.Z,ga.Z],[le.Y,ga.Y]]),l6=e=>/^[a-z]$/.test(e.toLowerCase()),U3=(e,t)=>{if(t===e.key.toLowerCase())return!0;let n=U6.get(t);return!!(n&&!l6(e.key)&&e.code===n)},l3=e=>e===le.ARROW_LEFT||e===le.ARROW_RIGHT||e===le.ARROW_DOWN||e===le.ARROW_UP,f3=e=>e.altKey,p3=e=>e.shiftKey,So=e=>e.shiftKey;var te=(e,t,n)=>Math.min(Math.max(e,t),n),xa=(e,t,n="round")=>{let r=Math.pow(10,t);return Math[n]((e+Number.EPSILON)*r)/r},E3=(e,t,n="round")=>{let r=1/t;return Math[n](e*r)/r},Pn=(e,t)=>(e+t)/2,Ir=e=>typeof e=="number"&&Number.isFinite(e),Po=(e,t,n=1e-4)=>Math.abs(e-t)<n;var h3=e=>e<0?e+2*Math.PI:e>=2*Math.PI?e-2*Math.PI:e;function _n(e){return e*Math.PI/180}function y3(e){return e*180/Math.PI}function ha(e){return Math.abs(Math.sin(2*e))<1e-4}function Me(e,t,n=0,r=0){return[e-n,t-r]}function M(e,t=[0,0]){return Me(e[0]-t[0],e[1]-t[1])}function X(e,t){return e[0]*t[1]-t[0]*e[1]}function f6(e,t){return e[0]*t[0]+e[1]*t[1]}function Ge(e,t){return[e[0]+t[0],e[1]+t[1]]}function wr(e,t){return[e[0]-t[0],e[1]-t[1]]}function G(e,t){return Me(e[0]*t,e[1]*t)}function p6(e){return e[0]*e[0]+e[1]*e[1]}function u6(e){return Math.sqrt(p6(e))}var Le=e=>{let t=u6(e);return t===0?Me(0,0):Me(e[0]/t,e[1]/t)};function u(e,t){return[e,t]}function Bn(e){return e.length===2?u(e[0],e[1]):void 0}function H(e,t=u(0,0)){return u(t[0]+e[0],t[1]+e[1])}function Rr(e){return Array.isArray(e)&&e.length===2&&typeof e[0]=="number"&&!isNaN(e[0])&&typeof e[1]=="number"&&!isNaN(e[1])}function Re(e,t){let n=Math.abs;return n(e[0]-t[0])<1e-4&&n(e[1]-t[1])<1e-4}function L([e,t],[n,r],o){return u((e-n)*Math.cos(o)-(t-r)*Math.sin(o)+n,(e-n)*Math.sin(o)+(t-r)*Math.cos(o)+r)}function On(e,t=[0,0]){return u(e[0]+t[0],e[1]+t[1])}function un(e,t){return u((e[0]+t[0])/2,(e[1]+t[1])/2)}function Q(e,t){return Math.hypot(t[0]-e[0],t[1]-e[1])}function pt(e,t){let n=t[0]-e[0],r=t[1]-e[1];return n*n+r*r}var zt=(e,t,n)=>On(t,G(M(e,t),n)),Tr=(e,t,n)=>t[0]<=Math.max(e[0],n[0])&&t[0]>=Math.min(e[0],n[0])&&t[1]<=Math.max(e[1],n[1])&&t[1]>=Math.min(e[1],n[1]);function Kn(e,t){return[e,t]}function ya(e,t){let n=e[1][1]-e[0][1],r=e[0][0]-e[1][0],o=t[1][1]-t[0][1],i=t[0][0]-t[1][0],a=n*i-o*r;if(a!==0){let s=n*e[0][0]+r*e[0][1],d=o*t[0][0]+i*t[0][1];return u((s*i-d*r)/a,(n*d-o*s)/a)}return null}function B(e,t){return[e,t]}var jt=(e,t,n=1e-4)=>{let r=Lr(e,t);return r===0?!0:r<n},Lr=(e,t)=>{let[n,r]=e,[[o,i],[a,s]]=t,d=n-o,U=r-i,l=a-o,f=s-i,p=d*l+U*f,b=l*l+f*f,m=-1;b!==0&&(m=p/b);let E,g;m<0?(E=o,g=i):m>1?(E=a,g=s):(E=o+m*l,g=i+m*f);let y=n-E,x=r-g;return Math.sqrt(y*y+x*x)};function _t(e,t,n){let r=ya(Kn(e[0],e[1]),Kn(t[0],t[1]));return!r||!jt(r,t,n)||!jt(r,e,n)?null:r}function Jn(e,t){return[e,t]}function Ia(e,t){return[B(e[0],u(e[1][0],e[0][1])),B(u(e[1][0],e[0][1]),e[1]),B(e[1],u(e[0][0],e[1][1])),B(u(e[0][0],e[1][1]),e[0])].map(n=>_t(t,n)).filter(n=>!!n)}function nt(e,t,n,r){return[e,t,n,r]}function wa(e,t,n,r=1e-6){return[(e(t+r,n)-e(t-r,n))/(2*r),(e(t,n+r)-e(t,n-r))/(2*r)]}function b6(e,t,n,r=.001,o=10){let i=1/0,a=0;for(;i>=r;){if(a>=o)return null;let s=e(t,n),d=[wa((E,g)=>e(E,g)[0],t,n),wa((E,g)=>e(E,g)[1],t,n)],U=[[-s[0]],[-s[1]]],l=d[0][0]*d[1][1]-d[0][1]*d[1][0];if(l===0)return null;let f=[[d[1][1]/l,-d[0][1]/l],[-d[1][0]/l,d[0][0]/l]],p=[[f[0][0]*U[0][0]+f[0][1]*U[1][0]],[f[1][0]*U[0][0]+f[1][1]*U[1][0]]];t=t+p[0][0],n=n+p[1][0];let[b,m]=e(t,n);i=Math.max(Math.abs(b),Math.abs(m)),a+=1}return[t,n]}var Hn=(e,t)=>u((1-t)**3*e[0][0]+3*(1-t)**2*t*e[1][0]+3*(1-t)*t**2*e[2][0]+t**3*e[3][0],(1-t)**3*e[0][1]+3*(1-t)**2*t*e[1][1]+3*(1-t)*t**2*e[2][1]+t**3*e[3][1]);function _o(e,t){let n=m6(e);if(Ia(Jn(u(n[0],n[1]),u(n[2],n[3])),t).length===0)return[];let r=s=>u(t[0][0]+s*(t[1][0]-t[0][0]),t[0][1]+s*(t[1][1]-t[0][1])),o=[[.5,0],[.2,0],[.8,0]],i=([s,d])=>{let U=b6((p,b)=>{let m=Hn(e,p),E=r(b);return[m[0]-E[0],m[1]-E[1]]},s,d);if(!U)return null;let[l,f]=U;return l<0||l>1||f<0||f>1?null:Hn(e,l)},a=i(o[0]);return a?[a]:(a=i(o[1]),a?[a]:(a=i(o[2]),a?[a]:[]))}function E6(e,t,n=.001){let r=(U,l,f,p=n)=>{let b=U,m=l,E;for(;m-b>p;)E=(m+b)/2,f(E-p)<f(E+p)?m=E:b=E;return E},i=0;for(let U=1/0,l=0;l<30;l++){let f=Q(t,Hn(e,l/30));f<U&&(U=f,i=l)}let a=Math.max((i-1)/30,0),s=Math.min((i+1)/30,1),d=r(a,s,U=>Q(t,Hn(e,U)));return d?Hn(e,d):null}function Bo(e,t){let n=E6(e,t);return n?Q(t,n):0}function m6(e){let[t,n,r,o]=e,i=[t[0],n[0],r[0],o[0]],a=[t[1],n[1],r[1],o[1]];return[Math.min(...i),Math.min(...a),Math.max(...i),Math.max(...a)]}function Oo(...e){return Ta(e)}function bn(e){return Ta(e)}var Ko=(e,t)=>{let n=e[0],r=e[1],o=!1;for(let i=0,a=t.length-1;i<t.length;a=i++){let s=t[i][0],d=t[i][1],U=t[a][0],l=t[a][1];(d>r&&l<=r||d<=r&&l>r)&&n<(U-s)*(r-d)/(l-d)+s&&(o=!o)}return o},Q3=(e,t)=>{let[n,r]=e,o=0;for(let i=0;i<t.length;i++){let a=(i+1)%t.length,[s,d]=t[i],[U,l]=t[a];d<=r?l>r&&(U-s)*(r-d)-(n-s)*(l-d)>0&&o++:l<=r&&(U-s)*(r-d)-(n-s)*(l-d)<0&&o--}return o!==0},Ra=(e,t,n=1e-4)=>{let r=!1;for(let o=0,i=t.length-1;o<i;o++)if(jt(e,B(t[o],t[o+1]),n)){r=!0;break}return r};function Ta(e){return g6(e)?e:[...e,e[0]]}function g6(e){return Re(e[0],e[e.length-1])}function Yn(e,t){return Ze([e,t])}var tb=([e,t],[n,r])=>e<=n?t>=n:e>=n?r>=e:!1,nb=([e,t],[n,r])=>{let o=Math.max(e,n),i=Math.min(t,r);return o<=i?Ze([o,i]):null},An=(e,[t,n])=>e>=t&&e<=n;function Mr([e,t,n],r){let o=(l,f,p)=>(l[0]-p[0])*(f[1]-p[1])-(f[0]-p[0])*(l[1]-p[1]),i=o(r,e,t),a=o(r,t,n),s=o(r,n,e),d=i<0||a<0||s<0,U=i>0||a>0||s>0;return!(d&&U)}var Bt=e=>{let t=e.map(r=>r[0]),n=e.map(r=>r[1]);return{width:Math.max(...t)-Math.min(...t),height:Math.max(...n)-Math.min(...n)}},Jo=(e,t,n,r)=>{let o=n.map(b=>b[e]),i=Math.max(...o),a=Math.min(...o),s=i-a,d=s===0?1:t/s,U=1/0,l=n.map(b=>{let m=b[e]*d,E=[...b];return E[e]=m,m<U&&(U=m),E});if(!r||l.length===2)return l;let f=a-U;return l.map(b=>b.map((m,E)=>E===e?m+f:m))},Ho=(e,t,n)=>n?[Math.round(e/n)*n,Math.round(t/n)*n]:[e,t];import h6 from"es6-promise-pool";var Vn=class{constructor(t,n){N(this,"pool");N(this,"entries",{});this.pool=new h6(t,n)}all(){let t=n=>{if(n.data.result){let[r,o]=n.data.result;this.entries[r]=o}};return this.pool.addEventListener("fulfilled",t),this.pool.start().then(()=>(setTimeout(()=>{this.pool.removeEventListener("fulfilled",t)}),Object.values(this.entries)))}};import{nanoid as T6}from"nanoid";import{Random as L6}from"roughjs/bin/math";var La=null;var Sb=()=>{if(La)return La;let e=new Date,t=e.getFullYear(),n=`${e.getMonth()+1}`.padStart(2,"0"),r=`${e.getDate()}`.padStart(2,"0"),o=`${e.getHours()}`.padStart(2,"0"),i=`${e.getMinutes()}`.padStart(2,"0");return`${t}-${n}-${r}-${o}${i}`},Pb=e=>e.charAt(0).toUpperCase()+e.slice(1),_b=e=>e instanceof HTMLElement&&e.className.includes("ToolIcon"),y6=e=>e instanceof HTMLElement&&e.dataset.type==="wysiwyg"||e instanceof HTMLBRElement||e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement,Bb=e=>y6(e)||e instanceof Element&&!!e.closest("label, button"),Ob=e=>e instanceof HTMLElement&&e.dataset.type==="wysiwyg"||e instanceof HTMLBRElement||e instanceof HTMLTextAreaElement||e instanceof HTMLInputElement&&(e.type==="text"||e.type==="number"||e.type==="password"),Yo=({fontFamily:e})=>{for(let[t,n]of Object.entries(pe))if(n===e)return`${t}${pr(n).map(r=>`, ${r}`).join("")}`;return Zt},Ie=({fontSize:e,fontFamily:t})=>`${e}px ${Yo({fontFamily:t})}`,$r=(e,t)=>{let n=0,r=null,o=(...i)=>{r=i,clearTimeout(n),n=window.setTimeout(()=>{r=null,e(...i)},t)};return o.flush=()=>{if(clearTimeout(n),r){let i=r;r=null,e(...i)}},o.cancel=()=>{r=null,clearTimeout(n)},o},Da=(e,t)=>{let n=null,r=null,o=null,i=s=>{n=window.requestAnimationFrame(()=>{n=null,e(...s),r=null,o&&(r=o,o=null,i(r))})},a=(...s)=>{if($e()){e(...s);return}r=s,n===null?i(r):t?.trailing&&(o=s)};return a.flush=()=>{n!==null&&(cancelAnimationFrame(n),n=null),r&&(e(...o||r),r=o=null)},a.cancel=()=>{r=o=null,n!==null&&(cancelAnimationFrame(n),n=null)},a},va=e=>1-Math.pow(1-e,4),Ma=(e,t,n)=>(t-e)*va(n)+e,Kb=({fromValues:e,toValues:t,onStep:n,duration:r=250,interpolateValue:o,onStart:i,onEnd:a,onCancel:s})=>{let d=!1,U=0,l;function f(p){if(d)return;l===void 0&&(l=p,i?.());let b=Math.min(p-l,r),m=va(b/r),E={};if(Object.keys(e).forEach(g=>{let y=g,x=(t[y]-e[y])*m+e[y];E[y]=x}),n(E),b<r){let g=b/r,y={};Object.keys(e).forEach(x=>{let h=x,R=e[h],I=t[h],v;v=o?o(R,I,g,h):Ma(R,I,g),v==null&&(v=Ma(R,I,g)),y[h]=v}),n(y),U=window.requestAnimationFrame(f)}else n(t),a?.()}return U=window.requestAnimationFrame(f),()=>{s?.(),d=!0,window.cancelAnimationFrame(U)}},Jb=(e,t)=>{if(!e.length||t<1)return[];let n=0,r=0,o=Array(Math.ceil(e.length/t));for(;n<e.length;)o[r++]=e.slice(n,n+=t);return o};var ke=(e,t)=>Math.abs(e-t),Na=(e,t)=>t.type==="custom"?{...e.activeTool,type:"custom",customType:t.customType,locked:t.locked??e.activeTool.locked}:{...e.activeTool,lastActiveTool:t.lastActiveToolBeforeEraser===void 0?e.activeTool.lastActiveTool:t.lastActiveToolBeforeEraser,type:t.type,customType:null,locked:t.locked??e.activeTool.locked,fromSelection:t.fromSelection??!1};var Hb=e=>(e=e.replace(/\bAlt\b/i,"Alt").replace(/\bShift\b/i,"Shift").replace(/\b(Enter|Return)\b/i,"Enter"),lr?e.replace(/\bCtrlOrCmd\b/gi,"Cmd").replace(/\bAlt\b/i,"Option"):e.replace(/\bCtrlOrCmd\b/gi,"Ctrl")),en=({clientX:e,clientY:t},{zoom:n,offsetLeft:r,offsetTop:o,scrollX:i,scrollY:a})=>{let s=(e-r)/n.value-i,d=(t-o)/n.value-a;return{x:s,y:d}},Ao=({sceneX:e,sceneY:t},{zoom:n,offsetLeft:r,offsetTop:o,scrollX:i,scrollY:a})=>{let s=(e+i)*n.value+r,d=(t+a)*n.value+o;return{x:s,y:d}},Yb=e=>getComputedStyle(document.documentElement).getPropertyValue(`--${e}`),I6="A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u0300-\u0590\u0800-\u1FFF\u2C00-\uFB1C\uFDFE-\uFE6F\uFEFD-\uFFFF",w6="\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC",R6=new RegExp(`^[^${I6}]*[${w6}]`),Dr=e=>R6.test(e),Ot=e=>{let[t,n]=e;return{x:t,y:n}},Ab=e=>{if(e?.name==="AbortError"){console.warn(e);return}throw e},Vb=(e,t,n=0)=>{n<0&&(n=e.length+n),n=Math.min(e.length,Math.max(n,0));let r=n-1;for(;++r<e.length;)if(t(e[r],r,e))return r;return-1},qb=(e,t,n=e.length-1)=>{n<0&&(n=e.length+n),n=Math.min(e.length-1,Math.max(n,0));let r=n+1;for(;--r>-1;)if(t(e[r],r,e))return r;return-1},ht=e=>{let t=e.length===5&&e.substr(4,1)==="0",n=e.length===9&&e.substr(7,2)==="00";return t||n||e===V.transparent},vr=e=>e.fillStyle!=="solid"||ht(e.backgroundColor),ma=()=>{let e,t,n=new Promise((r,o)=>{e=r,t=o});return n.resolve=e,n.reject=t,n};var Cb=e=>{let t=e.parentElement;for(;t;){if(t===document.body)return document;let{overflowY:n}=window.getComputedStyle(t);if(t.scrollHeight>t.clientHeight&&(n==="auto"||n==="scroll"||n==="overlay"))return t;t=t.parentElement}return document},Xb=e=>{let t=e.parentElement;for(;t;){if(t.tabIndex>-1){t.focus();return}t=t.parentElement}},Gb=e=>{e.preventDefault(),e.returnValue=""},Fa=e=>Array.from(e).map(t=>`0${t.toString(16)}`.slice(-2)).join(""),Kt=()=>$e()?1:Date.now(),de=e=>e instanceof Map?e:e.reduce((t,n)=>(t.set(typeof n=="string"?n:n.id,n),t),new Map),Zb=e=>e.reduce((t,n,r)=>(t.set(n.id,[n,r]),t),new Map),kb=(e,t)=>e.reduce((n,r)=>(n[t?t(r):String(r)]=r,n),{}),Wb=e=>e.reduce((t,n,r)=>{let o={...n,prev:null,next:null};if(r!==0){let i=t[r-1];if(o.prev=i,i.next=o,r===e.length-1){let a=t[0];o.next=a,a.prev=o}}return t.push(o),t},[]),$e=()=>$.MODE===fr.TEST,rt=()=>$.MODE===fr.DEVELOPMENT,Sa=()=>$.MODE===fr.PRODUCTION,Pa=()=>typeof process<"u"&&!0,Qb=(e,t)=>new CustomEvent(e,{detail:{nativeEvent:t},cancelable:!0}),zb=(e,t)=>{let n=!1;for(let r in t){let o=t[r];if(typeof o<"u"){if(e[r]===o&&(typeof o!="object"||o===null))continue;n=!0}}return n?{...e,...t}:e};var jb=()=>{try{return window.self===window.top?"top":"iframe"}catch{return"iframe"}};var _a=e=>!!e&&typeof e=="object"&&"then"in e&&"catch"in e&&"finally"in e,eE=e=>{let t=e?.querySelectorAll("button, a, input, select, textarea, div[tabindex], label[tabindex]");return t?Array.from(t).filter(n=>n.tabIndex>-1&&!n.disabled):[]},$a=(e,t)=>Array.isArray(e)&&Array.isArray(t)&&e.length===0&&t.length===0?!0:e===t,Vo=(e,t,n,r=!1)=>{let o=Object.keys(e),i=Object.keys(t);if(o.length!==i.length)return r&&console.warn("%cisShallowEqual: objects don't have same properties ->","color: #8B4000",e,t),!1;if(n&&Array.isArray(n)){for(let a of n)if(!(e[a]===t[a]||$a(e[a],t[a])))return r&&console.warn(`%cisShallowEqual: ${a} not equal ->`,"color: #8B4000",e[a],t[a]),!1;return!0}return o.every(a=>{let s=n?.[a],d=s?s(e[a],t[a]):e[a]===t[a]||$a(e[a],t[a]);return!d&&r&&console.warn(`%cisShallowEqual: ${a} not equal ->`,"color: #8B4000",e[a],t[a]),d})},tE=(e,t,{checkForDefaultPrevented:n=!0}={})=>function(o){if(e?.(o),!n||!o?.defaultPrevented)return t?.(o)},Nr=(e,t,n)=>{if(!t)return e;if(n)return console.error(t),e;throw new Error(t)};function be(e,t){if(!e)throw new Error(t)}var nE=e=>{let t,n,r=function(o){let i=Object.entries(o);if(t){let s=!0;for(let[d,U]of i)if(t.get(d)!==U){s=!1;break}if(s)return n}let a=e(o);return t=new Map(i),n=a,a};return r.clear=()=>{t=void 0,n=void 0},r},rE=(e,t)=>e instanceof Set||e instanceof Map?e.has(t):"includes"in e?e.includes(t):e.hasOwnProperty(t),oE=e=>JSON.parse(JSON.stringify(e)),iE=(e,t)=>Vo(e,t)?e:t;function aE(e,t,n,r){return e?(e?.addEventListener?.(t,n,r),()=>{e?.removeEventListener?.(t,n,r)}):()=>{}}function sE(e,t=!0){let n=e.length;if(n<4)return"";let r=e[0],o=e[1],i=e[2],a=`M${r[0].toFixed(2)},${r[1].toFixed(2)} Q${o[0].toFixed(2)},${o[1].toFixed(2)} ${Pn(o[0],i[0]).toFixed(2)},${Pn(o[1],i[1]).toFixed(2)} T`;for(let s=2,d=n-1;s<d;s++)r=e[s],o=e[s+1],a+=`${Pn(r[0],o[0]).toFixed(2)},${Pn(r[1],o[1]).toFixed(2)} `;return t&&(a+="Z"),a}var Ba=e=>e.replace(/\r?\n|\r/g,`
4
4
  `),Ze=e=>e,ft=async(e,...t)=>new Promise(n=>{n(e(...t))}),Oa=(...e)=>Math.max(...e.map(t=>t?1:0))>0;var En=e=>e.replace(/"/g,"&quot;"),dE=e=>Array.isArray(e)?e:[e],Ee=(e,t=0,n=0)=>{let{x:r,y:o,width:i,height:a}=e,s=r+i/2+t,d=o+a/2+n;return u(s,d)},qo=e=>Array.isArray(e),Ka=e=>qo(e)?e.length:e instanceof Map?e.size:Object.keys(e).length;var M6=new L6(Date.now()),$6=0,Jt=()=>Math.floor(M6.next()*2**31);var tn=()=>$e()?`id${$6++}`:T6();import{sanitizeUrl as D6}from"@braintree/sanitize-url";var yt=e=>(e=e.trim(),e&&D6(En(e))),gE=e=>!!(e?.includes(location.origin)||e?.startsWith("/")),Ja=e=>{if(e=yt(e),e.startsWith("/"))return`${location.origin}${e}`;try{new URL(e)}catch{return"about:blank"}return e};import{nanoid as Pu}from"nanoid";import Pi from"roughjs/bin/rough";import{pointsOnBezierCurves as v6}from"points-on-curve";var Fr=e=>{let{angle:t,width:n,height:r,x:o,y:i}=e,a=o+n/2,s=i+r/2,d=u(a,s),U;return e.type==="diamond"?U=Oo(L(u(a,i),d,t),L(u(o+n,s),d,t),L(u(a,i+r),d,t),L(u(o,s),d,t)):U=Oo(L(u(o,i),d,t),L(u(o+n,i),d,t),L(u(o+n,i+r),d,t),L(u(o,i+r),d,t)),{type:"polygon",data:U}},JE=(e,t,n=10)=>{let[r,o,i,a,s,d]=A(e,t,!0);r-=n,i+=n,o-=n,a+=n;let U=u(s,d),l=L(u(r,o),U,e.angle),f=L(u(i,o),U,e.angle),p=L(u(r,a),U,e.angle),b=L(u(i,a),U,e.angle);return{type:"polygon",data:[l,f,b,p]}},Ha=e=>{let{width:t,height:n,angle:r,x:o,y:i}=e;return{type:"ellipse",data:{center:u(o+t/2,i+n/2),angle:r,halfWidth:t/2,halfHeight:n/2}}},ot=e=>{if(!e)return[];for(let t of e.sets)if(t.type==="path")return t.ops;return e.sets[0].ops},Ya=(e,t=u(0,0),n,r)=>{let o=d=>L(u(d[0]+t[0],d[1]+t[1]),r,n),i=ot(e),a=[],s=u(0,0);for(let d of i){if(d.op==="move"){let U=Bn(d.data);be(U!=null,"Ops data is not a point"),s=o(U)}if(d.op==="bcurveTo"){let U=o(u(d.data[0],d.data[1])),l=o(u(d.data[2],d.data[3])),f=o(u(d.data[4],d.data[5]));a.push(nt(s,U,l,f)),s=f}}return{type:"polycurve",data:a}},N6=e=>{let t=e[0],n=[];for(let r=1;r<e.length;r++){let o=e[r];n.push(B(t,o)),t=o}return n},Aa=(e,t,n=!1)=>{let r=i=>L(H(Ge(M(i),Me(e.x,e.y))),t,e.angle),o=N6(e.points.map(i=>r(i)));return n?{type:"polygon",data:bn(o.flat())}:{type:"polyline",data:o}},Va=(e,t,n=u(0,0),r,o)=>{let i=l=>L(u(l[0]+n[0],l[1]+n[1]),o,r);if(e.roundness===null)return{type:"polygon",data:bn(e.points.map(l=>i(l)))};let a=ot(t),s=[],d=!1;for(let l of a)l.op==="move"?(d=!d,d&&s.push(u(l.data[0],l.data[1]))):l.op==="bcurveTo"?d&&(s.push(u(l.data[0],l.data[1])),s.push(u(l.data[2],l.data[3])),s.push(u(l.data[4],l.data[5]))):l.op==="lineTo"&&d&&s.push(u(l.data[0],l.data[1]));let U=v6(s,10,5).map(l=>i(l));return{type:"polygon",data:bn(U)}};var F6=(e,t)=>{let{angle:n,halfWidth:r,halfHeight:o,center:i}=t,a=r,s=o,d=Ge(M(e),G(M(i),-1)),[U,l]=L(H(d),u(0,0),-n),f=Math.abs(U),p=Math.abs(l),b=.707,m=.707;for(let y=0;y<3;y++){let x=a*b,h=s*m,R=(a*a-s*s)*b**3/a,I=(s*s-a*a)*m**3/s,v=x-R,P=h-I,S=f-R,F=p-I,_=Math.hypot(P,v),O=Math.hypot(F,S);b=Math.min(1,Math.max(0,(S*_/O+R)/a)),m=Math.min(1,Math.max(0,(F*_/O+I)/s));let J=Math.hypot(m,b);b/=J,m/=J}let[E,g]=[a*b*Math.sign(U),s*m*Math.sign(l)];return Q(u(U,l),u(E,g))},qa=(e,t,n=1e-4)=>F6(e,t)<=n,Ca=(e,t)=>{let{center:n,angle:r,halfWidth:o,halfHeight:i}=t,a=Ge(M(e),G(M(n),-1)),[s,d]=L(H(a),u(0,0),-r);return s/o*(s/o)+d/i*(d/i)<=1};import{pointsOnBezierCurves as Pd}from"points-on-curve";import{RoughGenerator as T8}from"roughjs/bin/generator";import{simplify as y8}from"points-on-curve";var Ht=e=>!!e&&e.type==="image"&&!!e.fileId,mn=e=>!!e&&e.type==="image",Sr=e=>!!e&&e.type==="embeddable",Pr=e=>!!e&&e.type==="iframe",it=e=>!!e&&(e.type==="iframe"||e.type==="embeddable"),z=e=>e!=null&&e.type==="text",Xa=e=>e!=null&&e.type==="frame",Ga=e=>e!=null&&e.type==="magicframe",me=e=>e!=null&&(e.type==="frame"||e.type==="magicframe"),Ae=e=>e!=null&&S6(e.type),S6=e=>e==="freedraw",ge=e=>e!=null&&Co(e.type),j=e=>e!=null&&e.type==="arrow",q=e=>j(e)&&e.elbowed,Co=e=>e==="arrow"||e==="line",Xo=(e,t=!0)=>e!=null&&(!e.locked||t===!0)&&P6(e.type),P6=e=>e==="arrow",It=(e,t=!0)=>e!=null&&(!e.locked||t===!0)&&(e.type==="rectangle"||e.type==="diamond"||e.type==="ellipse"||e.type==="image"||e.type==="iframe"||e.type==="embeddable"||e.type==="frame"||e.type==="magicframe"||e.type==="text"&&!e.containerId),Za=e=>e!=null&&(e.type==="rectangle"||e.type==="diamond"||e.type==="image"||e.type==="iframe"||e.type==="embeddable"||e.type==="frame"||e.type==="magicframe"||e.type==="text"&&!e.containerId);var _6=(e,t=!0)=>e!=null&&(!e.locked||t===!0)&&(e.type==="rectangle"||e.type==="diamond"||e.type==="ellipse"||j(e)),ka=e=>{let t=e?.type;if(!t)return!1;switch(t){case"text":case"diamond":case"rectangle":case"iframe":case"embeddable":case"ellipse":case"arrow":case"freedraw":case"line":case"frame":case"magicframe":case"image":case"selection":return!0;default:return Nr(t,null),!1}},VE=e=>e.type==="rectangle"||e.type==="ellipse"||e.type==="diamond",gn=e=>_6(e)&&!!e.boundElements?.some(({type:t})=>t==="text"),at=e=>e!==null&&"containerId"in e&&e.containerId!==null&&z(e),_r=e=>e==="rectangle"||e==="embeddable"||e==="iframe"||e==="image",Wa=e=>e==="line"||e==="arrow"||e==="diamond",qE=(e,t)=>!!((e===He.ADAPTIVE_RADIUS||e===He.LEGACY)&&_r(t.type)||e===He.PROPORTIONAL_RADIUS&&Wa(t.type)),CE=e=>Wa(e.type)?{type:He.PROPORTIONAL_RADIUS}:_r(e.type)?{type:He.ADAPTIVE_RADIUS}:null,nn=e=>Object.hasOwn(e,"fixedPoint")&&e.fixedPoint!=null;import B6 from"clsx";import O6 from"open-color";import De from"react";import{Fragment as oe,jsx as c,jsxs as T}from"react/jsx-runtime";var st=e=>"var(--icon-fill-color)",Qa=e=>e===Xe.LIGHT?O6.white:"#1e1e1e",w=(e,t=512)=>{let{width:n=512,height:r=n,mirror:o,style:i,...a}=typeof t=="number"?{width:t}:t;return c("svg",{"aria-hidden":"true",focusable:"false",role:"img",viewBox:`0 0 ${n} ${r}`,className:B6({"rtl-mirror":o}),style:i,...a,children:typeof e=="string"?c("path",{fill:"currentColor",d:e}):e})},D={width:24,height:24,fill:"none",strokeWidth:2,stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"},Y={width:20,height:20,fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"},zE=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("rect",{x:3,y:8,width:18,height:4,rx:1}),c("line",{x1:12,y1:8,x2:12,y2:21}),c("path",{d:"M19 12v7a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-7"}),c("path",{d:"M7.5 8a2.5 2.5 0 0 1 0 -5a4.8 8 0 0 1 4.5 5a4.8 8 0 0 1 4.5 -5a2.5 2.5 0 0 1 0 5"})]}),D),jE=w(T("g",{strokeWidth:"1.25",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 19a9 9 0 0 1 9 0a9 9 0 0 1 9 0"}),c("path",{d:"M3 6a9 9 0 0 1 9 0a9 9 0 0 1 9 0"}),c("line",{x1:"3",y1:"6",x2:"3",y2:"19"}),c("line",{x1:"12",y1:"6",x2:"12",y2:"19"}),c("line",{x1:"21",y1:"6",x2:"21",y2:"19"})]}),D),em=w(T("svg",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),c("line",{x1:"5",y1:"12",x2:"19",y2:"12"})]}),D),tm=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("circle",{cx:"12",cy:"12",r:"1"}),c("circle",{cx:"12",cy:"19",r:"1"}),c("circle",{cx:"12",cy:"5",r:"1"})]}),D),nm=w(T("svg",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M9 4v6l-2 4v2h10v-2l-2 -4v-6"}),c("line",{x1:"12",y1:"16",x2:"12",y2:"21"}),c("line",{x1:"8",y1:"4",x2:"16",y2:"4"})]}),D),rm=w(T("g",{children:[c("path",{d:"M13.542 8.542H6.458a2.5 2.5 0 0 0-2.5 2.5v3.75a2.5 2.5 0 0 0 2.5 2.5h7.084a2.5 2.5 0 0 0 2.5-2.5v-3.75a2.5 2.5 0 0 0-2.5-2.5Z",stroke:"currentColor",strokeWidth:"1.25"}),c("path",{d:"M10 13.958a1.042 1.042 0 1 0 0-2.083 1.042 1.042 0 0 0 0 2.083Z",stroke:"currentColor",strokeWidth:"1.25"}),c("mask",{id:"UnlockedIcon",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:6,y:1,width:9,height:9,children:c("path",{stroke:"none",d:"M6.399 9.561V5.175c0-.93.401-1.823 1.116-2.48a3.981 3.981 0 0 1 2.693-1.028c1.01 0 1.98.37 2.694 1.027.715.658 1.116 1.55 1.116 2.481",fill:"#fff"})}),c("g",{mask:"url(#UnlockedIcon)",children:c("path",{stroke:"none",d:"M5.149 9.561v1.25h2.5v-1.25h-2.5Zm5.06-7.894V.417v1.25Zm2.559 3.508v1.25h2.5v-1.25h-2.5ZM7.648 8.51V5.175h-2.5V8.51h2.5Zm0-3.334c0-.564.243-1.128.713-1.561L6.668 1.775c-.959.883-1.52 2.104-1.52 3.4h2.5Zm.713-1.561a2.732 2.732 0 0 1 1.847-.697v-2.5c-1.31 0-2.585.478-3.54 1.358L8.36 3.614Zm1.847-.697c.71 0 1.374.26 1.847.697l1.694-1.839a5.231 5.231 0 0 0-3.54-1.358v2.5Zm1.847.697c.47.433.713.997.713 1.561h2.5c0-1.296-.56-2.517-1.52-3.4l-1.693 1.839Z",fill:"currentColor"})})]}),Y),om=w(T("g",{strokeWidth:"1.25",children:[c("path",{d:"M13.542 8.542H6.458a2.5 2.5 0 0 0-2.5 2.5v3.75a2.5 2.5 0 0 0 2.5 2.5h7.084a2.5 2.5 0 0 0 2.5-2.5v-3.75a2.5 2.5 0 0 0-2.5-2.5Z"}),c("path",{d:"M10 13.958a1.042 1.042 0 1 0 0-2.083 1.042 1.042 0 0 0 0 2.083Z"}),c("path",{d:"M6.667 8.333V5.417C6.667 3.806 8.159 2.5 10 2.5c1.841 0 3.333 1.306 3.333 2.917v2.916"})]}),Y),im=w(T(oe,{children:[c("path",{d:"M38.5 83.5c-14-2-17.833-10.473-21-22.5C14.333 48.984 12 22 12 12.5",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"}),c("path",{fillRule:"evenodd",clipRule:"evenodd",d:"m12.005 10.478 7.905 14.423L6 25.75l6.005-15.273Z",fill:"currentColor"}),c("path",{d:"M12.005 10.478c1.92 3.495 3.838 7 7.905 14.423m-7.905-14.423c3.11 5.683 6.23 11.368 7.905 14.423m0 0c-3.68.226-7.35.455-13.91.85m13.91-.85c-5.279.33-10.566.647-13.91.85m0 0c1.936-4.931 3.882-9.86 6.005-15.273M6 25.75c2.069-5.257 4.135-10.505 6.005-15.272",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"})]}),{width:41,height:94,fill:"none"}),am=w(T(oe,{children:[c("path",{d:"M18.026 1.232c-5.268 13.125-5.548 33.555 3.285 42.311 8.823 8.75 33.31 12.304 42.422 13.523",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"}),c("path",{fillRule:"evenodd",clipRule:"evenodd",d:"m72.181 59.247-13.058-10-2.948 13.62 16.006-3.62Z",fill:"currentColor"}),c("path",{d:"M72.181 59.247c-3.163-2.429-6.337-4.856-13.058-10m13.058 10c-5.145-3.936-10.292-7.882-13.058-10m0 0c-.78 3.603-1.563 7.196-2.948 13.62m2.948-13.62c-1.126 5.168-2.24 10.346-2.948 13.62m0 0c5.168-1.166 10.334-2.343 16.006-3.62m-16.006 3.62c5.51-1.248 11.01-2.495 16.006-3.62",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"})]}),{width:85,height:71,fill:"none"}),sm=w(T(oe,{children:[c("path",{d:"M1 77c14-2 31.833-11.973 35-24 3.167-12.016-6-35-9.5-43.5",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"}),c("path",{fillRule:"evenodd",clipRule:"evenodd",d:"m24.165 1.093-2.132 16.309 13.27-4.258-11.138-12.05Z",fill:"currentColor"}),c("path",{d:"M24.165 1.093c-.522 3.953-1.037 7.916-2.132 16.309m2.131-16.309c-.835 6.424-1.68 12.854-2.13 16.308m0 0c3.51-1.125 7.013-2.243 13.27-4.257m-13.27 4.257c5.038-1.608 10.08-3.232 13.27-4.257m0 0c-3.595-3.892-7.197-7.777-11.14-12.05m11.14 12.05c-3.837-4.148-7.667-8.287-11.14-12.05",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round"})]}),{width:38,height:78,fill:"none"}),dm=w(c("g",{fill:"currentColor",children:c("path",{d:"M39.9 32.889a.326.326 0 0 0-.279-.056c-2.094-3.083-4.774-6-7.343-8.833l-.419-.472a.212.212 0 0 0-.056-.139.586.586 0 0 0-.167-.111l-.084-.083-.056-.056c-.084-.167-.28-.278-.475-.167-.782.39-1.507.973-2.206 1.528-.92.722-1.842 1.445-2.708 2.25a8.405 8.405 0 0 0-.977 1.028c-.14.194-.028.361.14.444-.615.611-1.23 1.223-1.843 1.861a.315.315 0 0 0-.084.223c0 .083.056.166.111.194l1.09.833v.028c1.535 1.528 4.244 3.611 7.12 5.861.418.334.865.667 1.284 1 .195.223.39.473.558.695.084.11.28.139.391.055.056.056.14.111.196.167a.398.398 0 0 0 .167.056.255.255 0 0 0 .224-.111.394.394 0 0 0 .055-.167c.029 0 .028.028.056.028a.318.318 0 0 0 .224-.084l5.082-5.528a.309.309 0 0 0 0-.444Zm-14.63-1.917a.485.485 0 0 0 .111.14c.586.5 1.2 1 1.843 1.555l-2.569-1.945-.251-.166c-.056-.028-.112-.084-.168-.111l-.195-.167.056-.056.055-.055.112-.111c.866-.861 2.346-2.306 3.1-3.028-.81.805-2.43 3.167-2.095 3.944Zm8.767 6.89-2.122-1.612a44.713 44.713 0 0 0-2.625-2.5c1.145.861 2.122 1.611 2.262 1.75 1.117.972 1.06.806 1.815 1.445l.921.666a1.06 1.06 0 0 1-.251.25Zm.558.416-.056-.028c.084-.055.168-.111.252-.194l-.196.222ZM1.089 5.75c.055.361.14.722.195 1.056.335 1.833.67 3.5 1.284 4.75l.252.944c.084.361.223.806.363.917 1.424 1.25 3.602 3.11 5.947 4.889a.295.295 0 0 0 .363 0s0 .027.028.027a.254.254 0 0 0 .196.084.318.318 0 0 0 .223-.084c2.988-3.305 5.221-6.027 6.813-8.305.112-.111.14-.278.14-.417.111-.111.195-.25.307-.333.111-.111.111-.306 0-.39l-.028-.027c0-.055-.028-.139-.084-.167-.698-.666-1.2-1.138-1.731-1.638-.922-.862-1.871-1.75-3.881-3.75l-.028-.028c-.028-.028-.056-.056-.112-.056-.558-.194-1.703-.389-3.127-.639C6.087 2.223 3.21 1.723.614.944c0 0-.168 0-.196.028l-.083.084c-.028.027-.056.055-.224.11h.056-.056c.028.167.028.278.084.473 0 .055.112.5.112.555l.782 3.556Zm15.496 3.278-.335-.334c.084.112.196.195.335.334Zm-3.546 4.666-.056.056c0-.028.028-.056.056-.056Zm-2.038-10c.168.167.866.834 1.033.973-.726-.334-2.54-1.167-3.379-1.445.838.167 1.983.334 2.346.472ZM1.424 2.306c.419.722.754 3.222 1.089 5.666-.196-.778-.335-1.555-.503-2.278-.251-1.277-.503-2.416-.838-3.416.056 0 .14 0 .252.028Zm-.168-.584c-.112 0-.223-.028-.307-.028 0-.027 0-.055-.028-.055.14 0 .223.028.335.083Zm-1.089.222c0-.027 0-.027 0 0ZM39.453 1.333c.028-.11-.558-.61-.363-.639.42-.027.42-.666 0-.666-.558.028-1.144.166-1.675.25-.977.194-1.982.389-2.96.61-2.205.473-4.383.973-6.561 1.557-.67.194-1.424.333-2.066.666-.224.111-.196.333-.084.472-.056.028-.084.028-.14.056-.195.028-.363.056-.558.083-.168.028-.252.167-.224.334 0 .027.028.083.028.11-1.173 1.556-2.485 3.195-3.909 4.945-1.396 1.611-2.876 3.306-4.356 5.056-4.719 5.5-10.052 11.75-15.943 17.25a.268.268 0 0 0 0 .389c.028.027.056.055.084.055-.084.084-.168.14-.252.222-.056.056-.084.111-.084.167a.605.605 0 0 0-.111.139c-.112.111-.112.305.028.389.111.11.307.11.39-.028.029-.028.029-.056.056-.056a.44.44 0 0 1 .615 0c.335.362.67.723.977 1.028l-.698-.583c-.112-.111-.307-.083-.39.028-.113.11-.085.305.027.389l7.427 6.194c.056.056.112.056.196.056s.14-.028.195-.084l.168-.166c.028.027.083.027.111.027.084 0 .14-.027.196-.083 10.052-10.055 18.15-17.639 27.42-24.417.083-.055.111-.166.111-.25.112 0 .196-.083.251-.194 1.704-5.194 2.039-9.806 2.15-12.083v-.028c0-.028.028-.056.028-.083.028-.056.028-.084.028-.084a1.626 1.626 0 0 0-.111-1.028ZM21.472 9.5c.446-.5.893-1.028 1.34-1.5-2.876 3.778-7.65 9.583-14.408 16.5 4.607-5.083 9.242-10.333 13.068-15ZM5.193 35.778h.084-.084Zm3.462 3.194c-.027-.028-.027-.028 0-.028v.028Zm4.16-3.583c.224-.25.448-.472.699-.722 0 0 0 .027.028.027-.252.223-.475.445-.726.695Zm1.146-1.111c.14-.14.279-.334.446-.5l.028-.028c1.648-1.694 3.351-3.389 5.082-5.111l.028-.028c.419-.333.921-.694 1.368-1.028a379.003 379.003 0 0 0-6.952 6.695ZM24.794 6.472c-.921 1.195-1.954 2.778-2.82 4.028-2.736 3.944-11.532 13.583-11.727 13.75a1976.983 1976.983 0 0 1-8.042 7.639l-.167.167c-.14-.167-.14-.417.028-.556C14.49 19.861 22.03 10.167 25.074 5.917c-.084.194-.14.36-.28.555Zm4.83 5.695c-1.116-.64-1.646-1.64-1.34-2.611l.084-.334c.028-.083.084-.194.14-.277.307-.5.754-.917 1.257-1.167.027 0 .055 0 .083-.028-.028-.056-.028-.139-.028-.222.028-.167.14-.278.335-.278.335 0 1.369.306 1.76.639.111.083.223.194.335.305.14.167.363.445.474.667.056.028.112.306.196.445.056.222.111.472.084.694-.028.028 0 .194-.028.194a2.668 2.668 0 0 1-.363 1.028c-.028.028-.028.056-.056.084l-.028.027c-.14.223-.335.417-.53.556-.643.444-1.369.583-2.095.389 0 0-.195-.084-.28-.111Zm8.154-.834a39.098 39.098 0 0 1-.893 3.167c0 .028-.028.083 0 .111-.056 0-.084.028-.14.056-2.206 1.61-4.356 3.305-6.506 5.028 1.843-1.64 3.686-3.306 5.613-4.945.558-.5.949-1.139 1.06-1.861l.28-1.667v-.055c.14-.334.67-.195.586.166Z",fill:"currentColor"})}),{width:40,height:40,fill:"none"}),za=w(T("g",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M6 6l4.153 11.793a0.365 .365 0 0 0 .331 .207a0.366 .366 0 0 0 .332 -.207l2.184 -4.793l4.787 -1.994a0.355 .355 0 0 0 .213 -.323a0.355 .355 0 0 0 -.213 -.323l-11.787 -4.36z"}),c("path",{d:"M13.5 13.5l4.5 4.5"})]}),{fill:"none",width:22,height:22,strokeWidth:1.25}),cm=w(T("g",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,children:[c("path",{d:"M4.028 13.252c-.657 -.972 -1.028 -2.078 -1.028 -3.252c0 -3.866 4.03 -7 9 -7s9 3.134 9 7s-4.03 7 -9 7c-1.913 0 -3.686 -.464 -5.144 -1.255"}),c("path",{d:"M5 15m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"}),c("path",{d:"M5 17c0 1.42 .316 2.805 1 4"})]}),{fill:"none",width:22,height:22,strokeWidth:1.25}),ja=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2"})]}),D),es=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M10.5 20.4l-6.9 -6.9c-.781 -.781 -.781 -2.219 0 -3l6.9 -6.9c.781 -.781 2.219 -.781 3 0l6.9 6.9c.781 .781 .781 2.219 0 3l-6.9 6.9c-.781 .781 -2.219 .781 -3 0z"})]}),D),ts=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("circle",{cx:"12",cy:"12",r:"9"})]}),D),ns=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"5",y1:"12",x2:"19",y2:"12"}),c("line",{x1:"15",y1:"16",x2:"19",y2:"12"}),c("line",{x1:"15",y1:"8",x2:"19",y2:"12"})]}),D),rs=w(c("path",{d:"M4.167 10h11.666",strokeWidth:"1.5"}),Y),Um=w(T("g",{strokeWidth:"1.25",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M20 17v-12c0 -1.121 -.879 -2 -2 -2s-2 .879 -2 2v12l2 2l2 -2z"}),c("path",{d:"M16 7h4"}),c("path",{d:"M18 19h-13a2 2 0 1 1 0 -4h4a2 2 0 1 0 0 -4h-3"})]}),D),os=w(T("g",{strokeWidth:"1.25",children:[c("path",{clipRule:"evenodd",d:"m7.643 15.69 7.774-7.773a2.357 2.357 0 1 0-3.334-3.334L4.31 12.357a3.333 3.333 0 0 0-.977 2.357v1.953h1.953c.884 0 1.732-.352 2.357-.977Z"}),c("path",{d:"m11.25 5.417 3.333 3.333"})]}),Y),is=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"20",x2:"7",y2:"20"}),c("line",{x1:"14",y1:"20",x2:"21",y2:"20"}),c("line",{x1:"6.9",y1:"15",x2:"13.8",y2:"15"}),c("line",{x1:"10.2",y1:"6.3",x2:"16",y2:"20"}),c("polyline",{points:"5 20 11 4 13 4 20 20"})]}),D),as=w(T("g",{strokeWidth:"1.25",children:[c("path",{d:"M12.5 6.667h.01"}),c("path",{d:"M4.91 2.625h10.18a2.284 2.284 0 0 1 2.285 2.284v10.182a2.284 2.284 0 0 1-2.284 2.284H4.909a2.284 2.284 0 0 1-2.284-2.284V4.909a2.284 2.284 0 0 1 2.284-2.284Z"}),c("path",{d:"m3.333 12.5 3.334-3.333c.773-.745 1.726-.745 2.5 0l4.166 4.166"}),c("path",{d:"m11.667 11.667.833-.834c.774-.744 1.726-.744 2.5 0l1.667 1.667"})]}),Y),ss=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M19 20h-10.5l-4.21 -4.3a1 1 0 0 1 0 -1.41l10 -10a1 1 0 0 1 1.41 0l5 5a1 1 0 0 1 0 1.41l-9.2 9.3"}),c("path",{d:"M18 13.3l-6.3 -6.3"})]}),D),lm=w(c("path",{strokeWidth:"1.25",d:"M10 4.167v11.666M4.167 10h11.666"}),Y),fm=w(c("path",{d:"M5 10h10",strokeWidth:"1.25"}),Y),pm=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M21 21l-6 -6"}),c("path",{d:"M3.268 12.043a7.017 7.017 0 0 0 6.634 4.957a7.012 7.012 0 0 0 7.043 -6.131a7 7 0 0 0 -5.314 -7.672a7.021 7.021 0 0 0 -8.241 4.403"}),c("path",{d:"M3 4v4h4"})]}),D),um=w(c("path",{strokeWidth:"1.25",d:"M3.333 5.833h13.334M8.333 9.167v5M11.667 9.167v5M4.167 5.833l.833 10c0 .92.746 1.667 1.667 1.667h6.666c.92 0 1.667-.746 1.667-1.667l.833-10M7.5 5.833v-2.5c0-.46.373-.833.833-.833h3.334c.46 0 .833.373.833.833v2.5"}),Y),bm=w(T("g",{strokeWidth:"1.5",children:[c("polyline",{points:"12 16 18 10 12 4"}),c("polyline",{points:"8 4 2 10 8 16"})]}),Y),Em=w(T("g",{strokeWidth:"1.25",children:[c("path",{d:"M14.375 6.458H8.958a2.5 2.5 0 0 0-2.5 2.5v5.417a2.5 2.5 0 0 0 2.5 2.5h5.417a2.5 2.5 0 0 0 2.5-2.5V8.958a2.5 2.5 0 0 0-2.5-2.5Z"}),c("path",{clipRule:"evenodd",d:"M11.667 3.125c.517 0 .986.21 1.325.55.34.338.55.807.55 1.325v1.458H8.333c-.485 0-.927.185-1.26.487-.343.312-.57.75-.609 1.24l-.005 5.357H5a1.87 1.87 0 0 1-1.326-.55 1.87 1.87 0 0 1-.549-1.325V5c0-.518.21-.987.55-1.326.338-.34.807-.549 1.325-.549h6.667Z"})]}),Y),mm=w(c("path",{clipRule:"evenodd",d:"M10 2.5h.328a6.25 6.25 0 0 0 6.6 10.372A7.5 7.5 0 1 1 10 2.493V2.5Z",stroke:"currentColor"}),Y),gm=w(c("g",{stroke:"currentColor",strokeLinejoin:"round",children:c("path",{d:"M10 12.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM10 4.167V2.5M14.167 5.833l1.166-1.166M15.833 10H17.5M14.167 14.167l1.166 1.166M10 15.833V17.5M5.833 14.167l-1.166 1.166M5 10H3.333M5.833 5.833 4.667 4.667"})}),{...Y,strokeWidth:1.5}),xm=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"6",x2:"20",y2:"6"}),c("line",{x1:"4",y1:"12",x2:"20",y2:"12"}),c("line",{x1:"4",y1:"18",x2:"20",y2:"18"})]}),D),hm=w(c("path",{strokeWidth:"1.25",d:"M3.333 14.167v1.666c0 .92.747 1.667 1.667 1.667h10c.92 0 1.667-.746 1.667-1.667v-1.666M5.833 9.167 10 13.333l4.167-4.166M10 3.333v10"}),Y),ym=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("circle",{cx:"12",cy:"12",r:"9"}),c("line",{x1:"12",y1:"17",x2:"12",y2:"17.01"}),c("path",{d:"M12 13.5a1.5 1.5 0 0 1 1 -1.5a2.6 2.6 0 1 0 -3 -4"})]}),D),Im=w(T("g",{strokeWidth:"1.25",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("circle",{cx:"12",cy:"12",r:"9"}),c("line",{x1:"12",y1:"17",x2:"12",y2:"17.01"}),c("path",{d:"M12 13.5a1.5 1.5 0 0 1 1 -1.5a2.6 2.6 0 1 0 -3 -4"})]}),D),wm=w(c("path",{strokeWidth:"1.25",d:"M9.167 5.833H5.833c-1.254 0-2.5 1.282-2.5 2.5v5.834c0 1.283 1.252 2.5 2.5 2.5h5.834c1.251 0 2.5-1.25 2.5-2.5v-3.334M8.333 11.667l8.334-8.334M12.5 3.333h4.167V7.5"}),Y),Rm=w(c("path",{d:"M7.5 15.833c-3.583 1.167-3.583-2.083-5-2.5m10 4.167v-2.917c0-.833.083-1.166-.417-1.666 2.334-.25 4.584-1.167 4.584-5a3.833 3.833 0 0 0-1.084-2.667 3.5 3.5 0 0 0-.083-2.667s-.917-.25-2.917 1.084a10.25 10.25 0 0 0-5.166 0C5.417 2.333 4.5 2.583 4.5 2.583a3.5 3.5 0 0 0-.083 2.667 3.833 3.833 0 0 0-1.084 2.667c0 3.833 2.25 4.75 4.584 5-.5.5-.5 1-.417 1.666V17.5",strokeWidth:"1.25"}),Y),Tm=w(T("g",{strokeWidth:"1.25",children:[c("path",{d:"M7.5 10.833a.833.833 0 1 0 0-1.666.833.833 0 0 0 0 1.666ZM12.5 10.833a.833.833 0 1 0 0-1.666.833.833 0 0 0 0 1.666ZM6.25 6.25c2.917-.833 4.583-.833 7.5 0M5.833 13.75c2.917.833 5.417.833 8.334 0"}),c("path",{d:"M12.917 14.167c0 .833 1.25 2.5 1.666 2.5 1.25 0 2.361-1.39 2.917-2.5.556-1.39.417-4.861-1.25-9.584-1.214-.846-2.5-1.116-3.75-1.25l-.833 2.084M7.083 14.167c0 .833-1.13 2.5-1.526 2.5-1.191 0-2.249-1.39-2.778-2.5-.529-1.39-.397-4.861 1.19-9.584 1.157-.846 2.318-1.116 3.531-1.25l.833 2.084"})]}),Y),Lm=w(T("g",{strokeWidth:"1.25",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 4l11.733 16h4.267l-11.733 -16z"}),c("path",{d:"M4 20l6.768 -6.768m2.46 -2.46l6.772 -6.772"})]}),D),Mm=w(c("polyline",{fill:"none",stroke:"currentColor",points:"20 6 9 17 4 12"}),{width:24,height:24}),$m=w(T("g",{strokeWidth:"1.25",children:[c("path",{d:"M8.333 11.667a2.917 2.917 0 0 0 4.167 0l3.333-3.334a2.946 2.946 0 1 0-4.166-4.166l-.417.416"}),c("path",{d:"M11.667 8.333a2.917 2.917 0 0 0-4.167 0l-3.333 3.334a2.946 2.946 0 0 0 4.166 4.166l.417-.416"})]}),Y),Dm=w("M433.941 129.941l-83.882-83.882A48 48 0 0 0 316.118 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h352c26.51 0 48-21.49 48-48V163.882a48 48 0 0 0-14.059-33.941zM224 416c-35.346 0-64-28.654-64-64 0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64zm96-304.52V212c0 6.627-5.373 12-12 12H76c-6.627 0-12-5.373-12-12V108c0-6.627 5.373-12 12-12h228.52c3.183 0 6.235 1.264 8.485 3.515l3.48 3.48A11.996 11.996 0 0 1 320 111.48z",{width:448,height:512}),vm=w("M252 54L203 8a28 27 0 00-20-8H28C12 0 0 12 0 27v195c0 15 12 26 28 26h204c15 0 28-11 28-26V73a28 27 0 00-8-19zM130 213c-21 0-37-16-37-36 0-19 16-35 37-35 20 0 37 16 37 35 0 20-17 36-37 36zm56-169v56c0 4-4 6-7 6H44c-4 0-7-2-7-6V42c0-4 3-7 7-7h133l4 2 3 2a7 7 0 012 5z M296 201l87 95-188 205-78 9c-10 1-19-8-18-20l9-84zm141-14l-41-44a31 31 0 00-46 0l-38 41 87 95 38-42c13-14 13-36 0-50z",{width:448,height:512}),Nm=w(c("path",{d:"m9.257 6.351.183.183H15.819c.34 0 .727.182 1.051.506.323.323.505.708.505 1.05v5.819c0 .316-.183.7-.52 1.035-.337.338-.723.522-1.037.522H4.182c-.352 0-.74-.181-1.058-.5-.318-.318-.499-.705-.499-1.057V5.182c0-.351.181-.736.5-1.054.32-.321.71-.503 1.057-.503H6.53l2.726 2.726Z",strokeWidth:"1.25"}),Y),Fm=w("M384 112v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V112c0-26.51 21.49-48 48-48h80c0-35.29 28.71-64 64-64s64 28.71 64 64h80c26.51 0 48 21.49 48 48zM192 40c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24m96 114v-20a6 6 0 0 0-6-6H102a6 6 0 0 0-6 6v20a6 6 0 0 0 6 6h180a6 6 0 0 0 6-6z",{width:384,height:512}),Sm=w("M204.3 5C104.9 24.4 24.8 104.3 5.2 203.4c-37 187 131.7 326.4 258.8 306.7 41.2-6.4 61.4-54.6 42.5-91.7-23.1-45.4 9.9-98.4 60.9-98.4h79.7c35.8 0 64.8-29.6 64.9-65.3C511.5 97.1 368.1-26.9 204.3 5zM96 320c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm32-128c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm128-64c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm128 64c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"),Pm=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M5 16l1.465 1.638a2 2 0 1 1 -3.015 .099l1.55 -1.737z"}),c("path",{d:"M13.737 9.737c2.299 -2.3 3.23 -5.095 2.081 -6.245c-1.15 -1.15 -3.945 -.217 -6.244 2.082c-2.3 2.299 -3.231 5.095 -2.082 6.244c1.15 1.15 3.946 .218 6.245 -2.081z"}),c("path",{d:"M7.492 11.818c.362 .362 .768 .676 1.208 .934l6.895 4.047c1.078 .557 2.255 -.075 3.692 -1.512c1.437 -1.437 2.07 -2.614 1.512 -3.692c-.372 -.718 -1.72 -3.017 -4.047 -6.895a6.015 6.015 0 0 0 -.934 -1.208"})]}),D),_m=w(T("g",{strokeWidth:"1.25",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M15 8h.01"}),c("path",{d:"M12 20h-5a3 3 0 0 1 -3 -3v-10a3 3 0 0 1 3 -3h10a3 3 0 0 1 3 3v5"}),c("path",{d:"M4 15l4 -4c.928 -.893 2.072 -.893 3 0l4 4"}),c("path",{d:"M14 14l1 -1c.617 -.593 1.328 -.793 2.009 -.598"}),c("path",{d:"M19 16v6"}),c("path",{d:"M22 19l-3 3l-3 -3"})]}),D),Bm=w("M216 0h80c13.3 0 24 10.7 24 24v168h87.7c17.8 0 26.7 21.5 14.1 34.1L269.7 378.3c-7.5 7.5-19.8 7.5-27.3 0L90.1 226.1c-12.6-12.6-3.7-34.1 14.1-34.1H192V24c0-13.3 10.7-24 24-24zm296 376v112c0 13.3-10.7 24-24 24H24c-13.3 0-24-10.7-24-24V376c0-13.3 10.7-24 24-24h146.7l49 49c20.1 20.1 52.5 20.1 72.6 0l49-49H488c13.3 0 24 10.7 24 24zm-124 88c0-11-9-20-20-20s-20 9-20 20 9 20 20 20 20-9 20-20zm64 0c0-11-9-20-20-20s-20 9-20 20 9 20 20 20 20-9 20-20z",{width:512,height:512}),Om=w("M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z",{width:448,height:512}),Km=w("M416 208H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z",{width:448,height:512}),Jm=w("M173.898 439.404l-166.4-166.4c-9.997-9.997-9.997-26.206 0-36.204l36.203-36.204c9.997-9.998 26.207-9.998 36.204 0L192 312.69 432.095 72.596c9.997-9.997 26.207-9.997 36.204 0l36.203 36.204c9.997 9.997 9.997 26.206 0 36.204l-294.4 294.401c-9.998 9.997-26.207 9.997-36.204-.001z"),Hm=w("M16 132h416c8.837 0 16-7.163 16-16V76c0-8.837-7.163-16-16-16H16C7.163 60 0 67.163 0 76v40c0 8.837 7.163 16 16 16zm0 160h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16zm0 160h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16z"),Ym=w(c("path",{d:"M7.5 10.833 4.167 7.5 7.5 4.167M4.167 7.5h9.166a3.333 3.333 0 0 1 0 6.667H12.5",strokeWidth:"1.25"}),Y),Am=w(c("path",{d:"M12.5 10.833 15.833 7.5 12.5 4.167M15.833 7.5H6.667a3.333 3.333 0 1 0 0 6.667H7.5",strokeWidth:"1.25"}),Y),Vm=w("M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zM262.655 90c-54.497 0-89.255 22.957-116.549 63.758-3.536 5.286-2.353 12.415 2.715 16.258l34.699 26.31c5.205 3.947 12.621 3.008 16.665-2.122 17.864-22.658 30.113-35.797 57.303-35.797 20.429 0 45.698 13.148 45.698 32.958 0 14.976-12.363 22.667-32.534 33.976C247.128 238.528 216 254.941 216 296v4c0 6.627 5.373 12 12 12h56c6.627 0 12-5.373 12-12v-1.333c0-28.462 83.186-29.647 83.186-106.667 0-58.002-60.165-102-116.531-102zM256 338c-25.365 0-46 20.635-46 46 0 25.364 20.635 46 46 46s46-20.636 46-46c0-25.365-20.635-46-46-46z",{mirror:!0}),qm=w(c("path",{d:"M5 12.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM15 7.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM15 17.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM7.25 8.917l5.5-2.834M7.25 11.083l5.5 2.834",strokeWidth:"1.5"}),Y),Cm=w("M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7 .2 40.1S486.3 480 472 480H40c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8 .2-40.1l216-368C228.7 39.5 241.8 32 256 32zm0 128c-13.3 0-24 10.7-24 24V296c0 13.3 10.7 24 24 24s24-10.7 24-24V184c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"),Xm=w("M16 5l-1.42 1.42-1.59-1.59V16h-1.98V4.83L9.42 6.42 8 5l4-4 4 4zm4 5v11c0 1.1-.9 2-2 2H6c-1.11 0-2-.9-2-2V10c0-1.11.89-2 2-2h3v2H6v11h12V10h-3V8h3c1.1 0 2 .89 2 2z",{width:24,height:24}),Gm=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M8 9h-1a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-8a2 2 0 0 0 -2 -2h-1"}),c("path",{d:"M12 14v-11"}),c("path",{d:"M9 6l3 -3l3 3"})]}),D),Zm=w(T(oe,{children:[c("path",{fill:"currentColor",d:"M40 5.6v6.1l-4.1.7c-8.9 1.4-16.5 6.9-20.6 15C13 32 10.9 43 12.4 43c.4 0 2.4-1.3 4.4-3 5-3.9 12.1-7 18.2-7.7l5-.6v12.8l11.2-11.3L62.5 22 51.2 10.8 40-.5v6.1zm10.2 22.6L44 34.5v-6.8l-6.9.6c-3.9.3-9.8 1.7-13.2 3.1-3.5 1.4-6.5 2.4-6.7 2.2-.9-1 3-7.5 6.4-10.8C28 18.6 34.4 16 40.1 16c3.7 0 3.9-.1 3.9-3.2V9.5l6.2 6.3 6.3 6.2-6.3 6.2z"}),c("path",{stroke:"currentColor",fill:"currentColor",d:"M0 36v20h48v-6.2c0-6 0-6.1-2-4.3-1.1 1-2 2.9-2 4.2V52H4V34c0-17.3-.1-18-2-18s-2 .7-2 20z"})]}),{width:64,height:64}),km=w(c("path",{stroke:"currentColor",strokeWidth:"40",fill:"currentColor",d:"M148 560a318 318 0 0 0 522 110 316 316 0 0 0 0-450 316 316 0 0 0-450 0c-11 11-21 22-30 34v4h47c25 0 46 21 46 46s-21 45-46 45H90c-13 0-25-6-33-14-9-9-14-20-14-33V156c0-25 20-45 45-45s45 20 45 45v32l1 1a401 401 0 0 1 623 509l212 212a42 42 0 0 1-59 59L698 757A401 401 0 0 1 65 570a42 42 0 0 1 83-10z"}),{width:1024}),ds=T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M12 10l0 10"}),c("path",{d:"M12 10l4 4"}),c("path",{d:"M12 10l-4 4"}),c("path",{d:"M4 4l16 0"})]}),cs=T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M12 5l0 14"}),c("path",{d:"M16 9l-4 -4"}),c("path",{d:"M8 9l4 -4"})]}),Wm=w(cs,D),Qm=w(cs,{...D,style:{transform:"rotate(180deg)"}}),zm=w(ds,D),jm=w(ds,{...D,style:{transform:"rotate(180deg)"}}),e4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M3.333 3.333h13.334",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M13.542 6.458h-.417c-.92 0-1.667.747-1.667 1.667v7.083c0 .92.746 1.667 1.667 1.667h.417c.92 0 1.666-.746 1.666-1.667V8.125c0-.92-.746-1.667-1.666-1.667ZM6.875 6.458h-.417c-.92 0-1.666.747-1.666 1.667v3.75c0 .92.746 1.667 1.666 1.667h.417c.92 0 1.667-.746 1.667-1.667v-3.75c0-.92-.747-1.667-1.667-1.667Z"})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),t4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M3.333 16.667h13.334",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M6.875 3.125h-.417c-.92 0-1.666.746-1.666 1.667v7.083c0 .92.746 1.667 1.666 1.667h.417c.92 0 1.667-.746 1.667-1.667V4.792c0-.92-.747-1.667-1.667-1.667ZM13.542 5.817h-.417c-.92 0-1.667.747-1.667 1.667v4.391c0 .92.746 1.667 1.667 1.667h.417c.92 0 1.666-.746 1.666-1.667V7.484c0-.92-.746-1.667-1.666-1.667Z"})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),n4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M3.333 3.333v13.334",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M15.208 4.792H8.125c-.92 0-1.667.746-1.667 1.666v.417c0 .92.747 1.667 1.667 1.667h7.083c.92 0 1.667-.747 1.667-1.667v-.417c0-.92-.746-1.666-1.667-1.666ZM12.516 11.458H8.125c-.92 0-1.667.746-1.667 1.667v.417c0 .92.747 1.666 1.667 1.666h4.391c.92 0 1.667-.746 1.667-1.666v-.417c0-.92-.746-1.667-1.667-1.667Z"})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),r4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M16.667 3.333v13.334",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M11.875 4.792H4.792c-.92 0-1.667.746-1.667 1.666v.417c0 .92.746 1.667 1.667 1.667h7.083c.92 0 1.667-.747 1.667-1.667v-.417c0-.92-.746-1.666-1.667-1.666ZM11.683 11.458H7.292c-.92 0-1.667.746-1.667 1.667v.417c0 .92.746 1.666 1.667 1.666h4.39c.921 0 1.667-.746 1.667-1.666v-.417c0-.92-.746-1.667-1.666-1.667Z"})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),o4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M16.667 3.333v13.334M3.333 3.333v13.334",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M14.375 10.208v-.416c0-.92-.746-1.667-1.667-1.667H7.292c-.92 0-1.667.746-1.667 1.667v.416c0 .92.746 1.667 1.667 1.667h5.416c.92 0 1.667-.746 1.667-1.667Z"})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),i4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M3.333 3.333h13.334M3.333 16.667h13.334",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M10.208 5.625h-.416c-.92 0-1.667.746-1.667 1.667v5.416c0 .92.746 1.667 1.667 1.667h.416c.92 0 1.667-.746 1.667-1.667V7.292c0-.92-.746-1.667-1.667-1.667Z"})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),a4=w(T("g",{stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M1.667 10h2.916",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M8.333 10h3.334",strokeLinejoin:"round"}),c("path",{d:"M15.417 10h2.916",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M6.875 4.792h-.417c-.92 0-1.666.746-1.666 1.666v7.084c0 .92.746 1.666 1.666 1.666h.417c.92 0 1.667-.746 1.667-1.666V6.458c0-.92-.747-1.666-1.667-1.666ZM13.542 6.458h-.417c-.92 0-1.667.747-1.667 1.667v3.75c0 .92.746 1.667 1.667 1.667h.417c.92 0 1.666-.746 1.666-1.667v-3.75c0-.92-.746-1.667-1.666-1.667Z"})]}),Y),s4=w(T("g",{stroke:"currentColor",strokeWidth:"1.25",children:[c("path",{d:"M10 18.333v-2.916",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M10 11.667V8.333",strokeLinejoin:"round"}),c("path",{d:"M10 4.583V1.667",strokeLinecap:"round",strokeLinejoin:"round"}),c("path",{d:"M4.792 13.125v.417c0 .92.746 1.666 1.666 1.666h7.084c.92 0 1.666-.746 1.666-1.666v-.417c0-.92-.746-1.667-1.666-1.667H6.458c-.92 0-1.666.746-1.666 1.667ZM6.458 6.458v.417c0 .92.747 1.667 1.667 1.667h3.75c.92 0 1.667-.747 1.667-1.667v-.417c0-.92-.746-1.666-1.667-1.666h-3.75c-.92 0-1.667.746-1.667 1.666Z"})]}),Y),d4=w(T("g",{strokeWidth:"1.5",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("circle",{cx:"9",cy:"7",r:"4"}),c("path",{d:"M3 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2"}),c("path",{d:"M16 3.13a4 4 0 0 1 0 7.75"}),c("path",{d:"M21 21v-2a4 4 0 0 0 -3 -3.85"})]}),D),c4=w("M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm115.7 272l-176 101c-15.8 8.8-35.7-2.5-35.7-21V152c0-18.4 19.8-29.8 35.7-21l176 107c16.4 9.2 16.4 32.9 0 42z"),U4=w("M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm96 328c0 8.8-7.2 16-16 16H176c-8.8 0-16-7.2-16-16V176c0-8.8 7.2-16 16-16h160c8.8 0 16 7.2 16 16v160z"),l4=w(T(oe,{children:[c("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round",children:c("path",{d:"M15 5 5 15M5 5l10 10"})}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),f4=w("M464 0c26.51 0 48 21.49 48 48v288c0 26.51-21.49 48-48 48H176c-26.51 0-48-21.49-48-48V48c0-26.51 21.49-48 48-48h288M176 416c-44.112 0-80-35.888-80-80V128H48c-26.51 0-48 21.49-48 48v288c0 26.51 21.49 48 48 48h288c26.51 0 48-21.49 48-48v-48H176z",{mirror:!0}),p4=w("M11.553 22.894a.998.998 0 00.894 0s3.037-1.516 5.465-4.097C19.616 16.987 21 14.663 21 12V5a1 1 0 00-.649-.936l-8-3a.998.998 0 00-.702 0l-8 3A1 1 0 003 5v7c0 2.663 1.384 4.987 3.088 6.797 2.428 2.581 5.465 4.097 5.465 4.097zm-1.303-8.481l6.644-6.644a.856.856 0 111.212 1.212l-7.25 7.25a.856.856 0 01-1.212 0l-3.75-3.75a.856.856 0 111.212-1.212l3.144 3.144z",{width:24}),u4=w("M369.9 97.9L286 14C277 5 264.8-.1 252.1-.1H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V131.9c0-12.7-5.1-25-14.1-34zM332.1 128H256V51.9l76.1 76.1zM48 464V48h160v104c0 13.3 10.7 24 24 24h104v288H48zm32-48h224V288l-23.5-23.5c-4.7-4.7-12.3-4.7-17 0L176 352l-39.5-39.5c-4.7-4.7-12.3-4.7-17 0L80 352v64zm48-240c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48z",{width:384,height:512}),b4=De.memo(({theme:e})=>w(T(oe,{children:[c("path",{d:"M25 26H111V111H25",fill:st(e)}),c("path",{d:"M25 111C25 80.2068 25 49.4135 25 26M25 26C48.6174 26 72.2348 26 111 26H25ZM25 26C53.3671 26 81.7343 26 111 26H25ZM111 26C111 52.303 111 78.606 111 111V26ZM111 26C111 51.2947 111 76.5893 111 111V26ZM111 111C87.0792 111 63.1585 111 25 111H111ZM111 111C87.4646 111 63.9293 111 25 111H111ZM25 111C25 81.1514 25 51.3028 25 26V111Z",stroke:st(e),strokeWidth:"2"}),c("path",{d:"M100 100H160V160H100",fill:st(e)}),c("path",{d:"M100 160C100 144.106 100 128.211 100 100M100 100C117.706 100 135.412 100 160 100H100ZM100 100C114.214 100 128.428 100 160 100H100ZM160 100C160 120.184 160 140.369 160 160V100ZM160 100C160 113.219 160 126.437 160 160V100ZM160 160C145.534 160 131.068 160 100 160H160ZM160 160C143.467 160 126.934 160 100 160H160ZM100 160C100 143.661 100 127.321 100 100V160Z",stroke:st(e),strokeWidth:"2"}),T("g",{fill:Qa(e),stroke:st(e),strokeWidth:"6",children:[c("rect",{x:"2.5",y:"2.5",width:"30",height:"30"}),c("rect",{x:"2.5",y:"149.5",width:"30",height:"30"}),c("rect",{x:"147.5",y:"149.5",width:"30",height:"30"}),c("rect",{x:"147.5",y:"2.5",width:"30",height:"30"})]})]}),{width:182,height:182,mirror:!0})),E4=De.memo(({theme:e})=>w(T(oe,{children:[c("path",{d:"M25 26H111V111H25",fill:st(e)}),c("path",{d:"M25 111C25 80.2068 25 49.4135 25 26M25 26C48.6174 26 72.2348 26 111 26H25ZM25 26C53.3671 26 81.7343 26 111 26H25ZM111 26C111 52.303 111 78.606 111 111V26ZM111 26C111 51.2947 111 76.5893 111 111V26ZM111 111C87.0792 111 63.1585 111 25 111H111ZM111 111C87.4646 111 63.9293 111 25 111H111ZM25 111C25 81.1514 25 51.3028 25 26V111Z",stroke:st(e),strokeWidth:"2"}),c("path",{d:"M100 100H160V160H100",fill:st(e)}),c("path",{d:"M100 160C100 144.106 100 128.211 100 100M100 100C117.706 100 135.412 100 160 100H100ZM100 100C114.214 100 128.428 100 160 100H100ZM160 100C160 120.184 160 140.369 160 160V100ZM160 100C160 113.219 160 126.437 160 160V100ZM160 160C145.534 160 131.068 160 100 160H160ZM160 160C143.467 160 126.934 160 100 160H160ZM100 160C100 143.661 100 127.321 100 100V160Z",stroke:st(e),strokeWidth:"2"}),T("g",{fill:Qa(e),stroke:st(e),strokeWidth:"6",children:[c("rect",{x:"2.5",y:"2.5",width:"30",height:"30"}),c("rect",{x:"78.5",y:"149.5",width:"30",height:"30"}),c("rect",{x:"147.5",y:"149.5",width:"30",height:"30"}),c("rect",{x:"147.5",y:"78.5",width:"30",height:"30"}),c("rect",{x:"105.5",y:"2.5",width:"30",height:"30"}),c("rect",{x:"2.5",y:"102.5",width:"30",height:"30"})]})]}),{width:182,height:182,mirror:!0})),m4=w(c("g",{strokeWidth:1.25,children:c("path",{d:"M5.879 2.625h8.242a3.27 3.27 0 0 1 3.254 3.254v8.242a3.27 3.27 0 0 1-3.254 3.254H5.88a3.27 3.27 0 0 1-3.254-3.254V5.88A3.27 3.27 0 0 1 5.88 2.626l-.001-.001ZM4.518 16.118l7.608-12.83m.198 13.934 5.051-9.897M2.778 9.675l9.348-6.387m-7.608 12.83 12.857-8.793"})}),Y),g4=w(T(oe,{children:[c("path",{d:"M5.879 2.625h8.242a3.254 3.254 0 0 1 3.254 3.254v8.242a3.254 3.254 0 0 1-3.254 3.254H5.88a3.254 3.254 0 0 1-3.254-3.254V5.88a3.254 3.254 0 0 1 3.254-3.254Z",stroke:"currentColor",strokeWidth:"1.25"}),c("mask",{id:"FillHachureIcon",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:2,y:2,width:16,height:16,children:c("path",{d:"M5.879 2.625h8.242a3.254 3.254 0 0 1 3.254 3.254v8.242a3.254 3.254 0 0 1-3.254 3.254H5.88a3.254 3.254 0 0 1-3.254-3.254V5.88a3.254 3.254 0 0 1 3.254-3.254Z",fill:"currentColor",stroke:"currentColor",strokeWidth:"1.25"})}),c("g",{mask:"url(#FillHachureIcon)",children:c("path",{d:"M2.258 15.156 15.156 2.258M7.324 20.222 20.222 7.325m-20.444 5.35L12.675-.222m-8.157 18.34L17.416 5.22",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})})]}),Y),x4=w(T(oe,{children:[T("g",{clipPath:"url(#a)",children:[c("path",{d:"M5.879 2.625h8.242a3.254 3.254 0 0 1 3.254 3.254v8.242a3.254 3.254 0 0 1-3.254 3.254H5.88a3.254 3.254 0 0 1-3.254-3.254V5.88a3.254 3.254 0 0 1 3.254-3.254Z",stroke:"currentColor",strokeWidth:"1.25"}),c("mask",{id:"FillCrossHatchIcon",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:-1,y:-1,width:22,height:22,children:c("path",{d:"M2.426 15.044 15.044 2.426M7.383 20 20 7.383M0 12.617 12.617 0m-7.98 17.941L17.256 5.324m-2.211 12.25L2.426 4.956M20 12.617 7.383 0m5.234 20L0 7.383m17.941 7.98L5.324 2.745",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})}),c("g",{mask:"url(#FillCrossHatchIcon)",children:c("path",{d:"M14.121 2H5.88A3.879 3.879 0 0 0 2 5.879v8.242A3.879 3.879 0 0 0 5.879 18h8.242A3.879 3.879 0 0 0 18 14.121V5.88A3.879 3.879 0 0 0 14.121 2Z",fill:"currentColor"})})]}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),h4=w(T(oe,{children:[c("g",{clipPath:"url(#a)",children:c("path",{d:"M4.91 2.625h10.18a2.284 2.284 0 0 1 2.285 2.284v10.182a2.284 2.284 0 0 1-2.284 2.284H4.909a2.284 2.284 0 0 1-2.284-2.284V4.909a2.284 2.284 0 0 1 2.284-2.284Z",stroke:"currentColor",strokeWidth:"1.25"})}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),{...Y,fill:"currentColor"}),y4=w(c(oe,{children:c("path",{d:"M4.167 10h11.666",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})}),Y),I4=w(c("path",{d:"M5 10h10",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round"}),Y),w4=w(c("path",{d:"M5 10h10",stroke:"currentColor",strokeWidth:"3.75",strokeLinecap:"round",strokeLinejoin:"round"}),Y),R4=De.memo(({theme:e})=>w(c("path",{d:"M6 10H34",stroke:st(e),strokeWidth:2,fill:"none",strokeLinecap:"round"}),{width:40,height:20})),T4=w(T("g",{strokeWidth:"2",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M5 12h2"}),c("path",{d:"M17 12h2"}),c("path",{d:"M11 12h2"})]}),D),L4=w(T("g",{strokeWidth:"2",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 12v.01"}),c("path",{d:"M8 12v.01"}),c("path",{d:"M12 12v.01"}),c("path",{d:"M16 12v.01"}),c("path",{d:"M20 12v.01"})]}),D),M4=w(c("path",{d:"M2.5 12.038c1.655-.885 5.9-3.292 8.568-4.354 2.668-1.063.101 2.821 1.32 3.104 1.218.283 5.112-1.814 5.112-1.814",strokeWidth:"1.25"}),Y),$4=w(c("path",{d:"M2.5 12.563c1.655-.886 5.9-3.293 8.568-4.355 2.668-1.062.101 2.822 1.32 3.105 1.218.283 5.112-1.814 5.112-1.814m-13.469 2.23c2.963-1.586 6.13-5.62 7.468-4.998 1.338.623-1.153 4.11-.132 5.595 1.02 1.487 6.133-1.43 6.133-1.43",strokeWidth:"1.25"}),Y),D4=w(c("path",{d:"M2.5 11.936c1.737-.879 8.627-5.346 10.42-5.268 1.795.078-.418 5.138.345 5.736.763.598 3.53-1.789 4.235-2.147M2.929 9.788c1.164-.519 5.47-3.28 6.987-3.114 1.519.165 1 3.827 2.121 4.109 1.122.281 3.839-2.016 4.606-2.42",strokeWidth:"1.25"}),Y),v4=w(T("svg",{strokeWidth:"1.5",children:[c("path",{d:"M3.33334 9.99998V6.66665C3.33334 6.04326 3.33403 4.9332 3.33539 3.33646C4.95233 3.33436 6.06276 3.33331 6.66668 3.33331H10"}),c("path",{d:"M13.3333 3.33331V3.34331"}),c("path",{d:"M16.6667 3.33331V3.34331"}),c("path",{d:"M16.6667 6.66669V6.67669"}),c("path",{d:"M16.6667 10V10.01"}),c("path",{d:"M3.33334 13.3333V13.3433"}),c("path",{d:"M16.6667 13.3333V13.3433"}),c("path",{d:"M3.33334 16.6667V16.6767"}),c("path",{d:"M6.66666 16.6667V16.6767"}),c("path",{d:"M10 16.6667V16.6767"}),c("path",{d:"M13.3333 16.6667V16.6767"}),c("path",{d:"M16.6667 16.6667V16.6767"})]}),Y),N4=w(T("g",{strokeWidth:"1.5",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 12v-4a4 4 0 0 1 4 -4h4"}),c("line",{x1:"16",y1:"4",x2:"16",y2:"4.01"}),c("line",{x1:"20",y1:"4",x2:"20",y2:"4.01"}),c("line",{x1:"20",y1:"8",x2:"20",y2:"8.01"}),c("line",{x1:"20",y1:"12",x2:"20",y2:"12.01"}),c("line",{x1:"4",y1:"16",x2:"4",y2:"16.01"}),c("line",{x1:"20",y1:"16",x2:"20",y2:"16.01"}),c("line",{x1:"4",y1:"20",x2:"4",y2:"20.01"}),c("line",{x1:"8",y1:"20",x2:"8",y2:"20.01"}),c("line",{x1:"12",y1:"20",x2:"12",y2:"20.01"}),c("line",{x1:"16",y1:"20",x2:"16",y2:"20.01"}),c("line",{x1:"20",y1:"20",x2:"20",y2:"20.01"})]}),D),F4=w(T("g",{stroke:"currentColor",opacity:.3,strokeWidth:2,children:[c("path",{d:"M12 12l9 0"}),c("path",{d:"M3 9l6 6"}),c("path",{d:"M3 15l6 -6"})]}),D),S4=De.memo(({flip:e=!1})=>w(T("g",{transform:e?"translate(40, 0) scale(-1, 1)":"",stroke:"currentColor",strokeWidth:2,fill:"none",children:[c("path",{d:"M34 10H6M34 10L27 5M34 10L27 15"}),c("path",{d:"M27.5 5L34.5 10L27.5 15"})]}),{width:40,height:20})),P4=De.memo(({flip:e=!1})=>w(T("g",{stroke:"currentColor",fill:"currentColor",transform:e?"translate(40, 0) scale(-1, 1)":"",children:[c("path",{d:"M32 10L6 10",strokeWidth:2}),c("circle",{r:"4",transform:"matrix(-1 0 0 1 30 10)"})]}),{width:40,height:20})),_4=De.memo(({flip:e=!1})=>w(T("g",{stroke:"currentColor",fill:"none",transform:e?"translate(40, 0) scale(-1, 1)":"",strokeWidth:2,children:[c("path",{d:"M26 10L6 10"}),c("circle",{r:"4",transform:"matrix(-1 0 0 1 30 10)"})]}),{width:40,height:20})),B4=De.memo(({flip:e=!1})=>w(c("g",{transform:e?"translate(40, 0) scale(-1, 1)":"",children:c("path",{d:"M34 10H5.99996M34 10L34 5M34 10L34 15",stroke:"currentColor",strokeWidth:2,fill:"none"})}),{width:40,height:20})),O4=De.memo(({flip:e=!1})=>w(T("g",{stroke:"currentColor",fill:"currentColor",transform:e?"translate(40, 0) scale(-1, 1)":"",children:[c("path",{d:"M32 10L6 10",strokeWidth:2}),c("path",{d:"M27.5 5.5L34.5 10L27.5 14.5L27.5 5.5"})]}),{width:40,height:20})),K4=De.memo(({flip:e=!1})=>w(T("g",{stroke:"currentColor",fill:"none",transform:e?"translate(40, 0) scale(-1, 1)":"",strokeWidth:2,strokeLinejoin:"round",children:[c("path",{d:"M6,9.5H27"}),c("path",{d:"M27,5L34,10L27,14Z",fill:"none"})]}),{width:40,height:20})),J4=De.memo(({flip:e=!1})=>w(T("g",{stroke:"currentColor",fill:"currentColor",transform:e?"translate(40, 0) scale(-1, 1)":"",strokeLinejoin:"round",strokeWidth:2,children:[c("path",{d:"M6,9.5H20"}),c("path",{d:"M27,5L34,10L27,14L20,9.5Z"})]}),{width:40,height:20})),H4=De.memo(({flip:e=!1})=>w(T("g",{stroke:"currentColor",fill:"none",transform:e?"translate(40, 0) scale(-1, 1)":"",strokeLinejoin:"round",strokeWidth:2,children:[c("path",{d:"M6,9.5H20"}),c("path",{d:"M27,5L34,10L27,14L20,9.5Z"})]}),{width:40,height:20})),Y4=De.memo(({flip:e=!1})=>w(c("g",{stroke:"currentColor",fill:"none",transform:e?"":"translate(40, 0) scale(-1, 1)",strokeLinejoin:"round",strokeWidth:2,children:c("path",{d:"M34,10 H6 M15,10 L7,5 M15,10 L7,15"})}),{width:40,height:20})),A4=De.memo(({flip:e=!1})=>w(c("g",{stroke:"currentColor",fill:"none",transform:e?"":"translate(40, 0) scale(-1, 1)",strokeLinejoin:"round",strokeWidth:2,children:c("path",{d:"M34,10 H6 M15,10 L15,15 L15,5"})}),{width:40,height:20})),V4=De.memo(({flip:e=!1})=>w(c("g",{stroke:"currentColor",fill:"none",transform:e?"":"translate(40, 0) scale(-1, 1)",strokeLinejoin:"round",strokeWidth:2,children:c("path",{d:"M34,10 H6 M15,10 L15,16 L15,4 M15,10 L7,5 M15,10 L7,15"})}),{width:40,height:20})),q4=w(T(oe,{children:[c("g",{clipPath:"url(#a)",children:c("path",{d:"M14.167 6.667a3.333 3.333 0 0 0-3.334-3.334H9.167a3.333 3.333 0 0 0 0 6.667h1.666a3.333 3.333 0 0 1 0 6.667H9.167a3.333 3.333 0 0 1-3.334-3.334",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),C4=w(T(oe,{children:[c("g",{clipPath:"url(#a)",children:c("path",{d:"M5 16.667V3.333L10 15l5-11.667v13.334",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),X4=w(T(oe,{children:[c("g",{clipPath:"url(#a)",children:c("path",{d:"M5.833 3.333v13.334h8.334",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),G4=w(c(oe,{children:c("path",{d:"m1.667 3.333 6.666 13.334M8.333 3.333 1.667 16.667M11.667 3.333v13.334h6.666",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round"})}),Y),Z4=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 7v-2h13v2"}),c("path",{d:"M10 5v14"}),c("path",{d:"M12 19h-4"}),c("path",{d:"M15 13v-1h6v1"}),c("path",{d:"M18 12v7"}),c("path",{d:"M17 19h2"})]}),D),k4=w(c(oe,{children:T("g",{stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M7 12h10"}),c("path",{d:"M7 5v14"}),c("path",{d:"M17 5v14"}),c("path",{d:"M15 19h4"}),c("path",{d:"M15 5h4"}),c("path",{d:"M5 19h4"}),c("path",{d:"M5 5h4"})]})}),D),W4=w(c(oe,{children:c("g",{stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round",children:c("path",{d:"M5.833 16.667v-10a3.333 3.333 0 0 1 3.334-3.334h1.666a3.333 3.333 0 0 1 3.334 3.334v10M5.833 10.833h8.334"})})}),Y),Q4=w(T(oe,{children:[c("g",{clipPath:"url(#a)",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round",children:c("path",{d:"M5.833 6.667 2.5 10l3.333 3.333M14.167 6.667 17.5 10l-3.333 3.333M11.667 3.333 8.333 16.667"})}),c("defs",{children:c("clipPath",{id:"a",children:c("path",{fill:"#fff",d:"M0 0h20v20H0z"})})})]}),Y),z4=w(T("g",{stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"8",x2:"20",y2:"8"}),c("line",{x1:"4",y1:"12",x2:"12",y2:"12"}),c("line",{x1:"4",y1:"16",x2:"16",y2:"16"})]}),D),j4=w(T("g",{stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"8",x2:"20",y2:"8"}),c("line",{x1:"8",y1:"12",x2:"16",y2:"12"}),c("line",{x1:"6",y1:"16",x2:"18",y2:"16"})]}),D),eg=w(T("g",{stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"8",x2:"20",y2:"8"}),c("line",{x1:"10",y1:"12",x2:"20",y2:"12"}),c("line",{x1:"8",y1:"16",x2:"20",y2:"16"})]}),D),tg=De.memo(({theme:e})=>w(T("g",{strokeWidth:"1.5",stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"4",x2:"20",y2:"4"}),c("rect",{x:"9",y:"8",width:"6",height:"12",rx:"2"})]}),D)),ng=De.memo(({theme:e})=>w(T("g",{strokeWidth:"2",stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"20",x2:"20",y2:"20"}),c("rect",{x:"9",y:"4",width:"6",height:"12",rx:"2"})]}),D)),rg=De.memo(({theme:e})=>w(T("g",{strokeWidth:"1.5",stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("line",{x1:"4",y1:"12",x2:"9",y2:"12"}),c("line",{x1:"15",y1:"12",x2:"20",y2:"12"}),c("rect",{x:"9",y:"6",width:"6",height:"12",rx:"2"})]}),D)),og=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M21 19h-18l9 -15"}),c("path",{d:"M20.615 15.171h.015"}),c("path",{d:"M19.515 11.771h.015"}),c("path",{d:"M17.715 8.671h.015"}),c("path",{d:"M15.415 5.971h.015"})]}),D),ig=w(c("path",{d:"M537.6 226.6c4.1-10.7 6.4-22.4 6.4-34.6 0-53-43-96-96-96-19.7 0-38.1 6-53.3 16.2C367 64.2 315.3 32 256 32c-88.4 0-160 71.6-160 160 0 2.7.1 5.4.2 8.1C40.2 219.8 0 273.2 0 336c0 79.5 64.5 144 144 144h368c70.7 0 128-57.3 128-128 0-61.9-44-113.6-102.4-125.4zM393.4 288H328v112c0 8.8-7.2 16-16 16h-48c-8.8 0-16-7.2-16-16V288h-65.4c-14.3 0-21.4-17.2-11.3-27.3l105.4-105.4c6.2-6.2 16.4-6.2 22.6 0l105.4 105.4c10.1 10.1 2.9 27.3-11.3 27.3z",fill:"currentColor"}),{width:640,height:512}),ag=w(c("path",{d:"M480 416C497.7 416 512 430.3 512 448C512 465.7 497.7 480 480 480H150.6C133.7 480 117.4 473.3 105.4 461.3L25.37 381.3C.3786 356.3 .3786 315.7 25.37 290.7L258.7 57.37C283.7 32.38 324.3 32.38 349.3 57.37L486.6 194.7C511.6 219.7 511.6 260.3 486.6 285.3L355.9 416H480zM265.4 416L332.7 348.7L195.3 211.3L70.63 336L150.6 416L265.4 416z"})),sg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M8 13v-7.5a1.5 1.5 0 0 1 3 0v6.5"}),c("path",{d:"M11 5.5v-2a1.5 1.5 0 1 1 3 0v8.5"}),c("path",{d:"M14 5.5a1.5 1.5 0 0 1 3 0v6.5"}),c("path",{d:"M17 7.5a1.5 1.5 0 0 1 3 0v8.5a6 6 0 0 1 -6 6h-2h.208a6 6 0 0 1 -5.012 -2.7a69.74 69.74 0 0 1 -.196 -.3c-.312 -.479 -1.407 -2.388 -3.286 -5.728a1.5 1.5 0 0 1 .536 -2.022a1.867 1.867 0 0 1 2.28 .28l1.47 1.47"})]}),D),dg=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2"}),c("path",{d:"M7 11l5 5l5 -5"}),c("path",{d:"M12 4l0 12"})]}),D),cg=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M8 8m0 2a2 2 0 0 1 2 -2h8a2 2 0 0 1 2 2v8a2 2 0 0 1 -2 2h-8a2 2 0 0 1 -2 -2z"}),c("path",{d:"M16 8v-2a2 2 0 0 0 -2 -2h-8a2 2 0 0 0 -2 2v8a2 2 0 0 0 2 2h2"})]}),D),Ug=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M7 17m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0"}),c("path",{d:"M17 17m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0"}),c("path",{d:"M9.15 14.85l8.85 -10.85"}),c("path",{d:"M6 4l8.85 10.85"})]}),D),lg=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"}),c("path",{d:"M12 17l0 .01"}),c("path",{d:"M12 13.5a1.5 1.5 0 0 1 1 -1.5a2.6 2.6 0 1 0 -3 -4"})]}),D),fg=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M7 4v16l13 -8z"})]}),D),pg=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M17 4h-10a3 3 0 0 0 -3 3v10a3 3 0 0 0 3 3h10a3 3 0 0 0 3 -3v-10a3 3 0 0 0 -3 -3z",strokeWidth:"0",fill:"currentColor"})]}),D),ug=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M5 12l5 5l10 -10"})]}),D),bg=w(T(oe,{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M10.24 3.957l-8.422 14.06a1.989 1.989 0 0 0 1.7 2.983h16.845a1.989 1.989 0 0 0 1.7 -2.983l-8.423 -14.06a1.989 1.989 0 0 0 -3.4 0z"}),c("path",{d:"M12 9v4"}),c("path",{d:"M12 17h.01"})]}),D),Eg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M11 7l6 6"}),c("path",{d:"M4 16l11.7 -11.7a1 1 0 0 1 1.4 0l2.6 2.6a1 1 0 0 1 0 1.4l-11.7 11.7h-4v-4z"})]}),D),mg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M12 3l-4 7h8z"}),c("path",{d:"M17 17m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0"}),c("path",{d:"M4 14m0 1a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1z"})]}),D),gg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 7l16 0"}),c("path",{d:"M4 17l16 0"}),c("path",{d:"M7 4l0 16"}),c("path",{d:"M17 4l0 16"})]}),D),xg=w(c("path",{fill:"currentColor",d:"M407.48,111.18C335.587,108.103 269.573,152.338 245.08,220C220.587,152.338 154.573,108.103 82.68,111.18C80.285,168.229 107.577,222.632 154.74,254.82C178.908,271.419 193.35,298.951 193.27,328.27L193.27,379.13L296.9,379.13L296.9,328.27C296.816,298.953 311.255,271.42 335.42,254.82C382.596,222.644 409.892,168.233 407.48,111.18Z"})),hg=w(T("g",{strokeWidth:"1.25",children:[c("path",{d:"M4.16602 10H15.8327"}),c("path",{d:"M12.5 13.3333L15.8333 10"}),c("path",{d:"M12.5 6.66666L15.8333 9.99999"})]}),Y),yg=w(T("g",{fill:"none",stroke:"currentColor",strokeWidth:"1.25",strokeLinecap:"round",strokeLinejoin:"round",transform:"rotate(90 10 10)",children:[c("path",{clipRule:"evenodd",d:"m9.644 13.69 7.774-7.773a2.357 2.357 0 0 0-3.334-3.334l-7.773 7.774L8 12l1.643 1.69Z"}),c("path",{d:"m13.25 3.417 3.333 3.333M10 10l2-2M5 15l3-3M2.156 17.894l1-1M5.453 19.029l-.144-1.407M2.377 11.887l.866 1.118M8.354 17.273l-1.194-.758M.953 14.652l1.408.13"})]}),20),Ig=w(T("g",{stroke:"currentColor",fill:"none",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z"}),c("path",{d:"M6 21l15 -15l-3 -3l-15 15l3 3"}),c("path",{d:"M15 6l3 3"}),c("path",{d:"M9 3a2 2 0 0 0 2 2a2 2 0 0 0 -2 2a2 2 0 0 0 -2 -2a2 2 0 0 0 2 -2"}),c("path",{d:"M19 13a2 2 0 0 0 2 2a2 2 0 0 0 -2 2a2 2 0 0 0 -2 -2a2 2 0 0 0 2 -2"})]}),D),wg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z"}),c("path",{d:"M6 21l15 -15l-3 -3l-15 15l3 3"}),c("path",{d:"M15 6l3 3"}),c("path",{d:"M9 3a2 2 0 0 0 2 2a2 2 0 0 0 -2 2a2 2 0 0 0 -2 -2a2 2 0 0 0 2 -2"}),c("path",{d:"M19 13a2 2 0 0 0 2 2a2 2 0 0 0 -2 2a2 2 0 0 0 -2 -2a2 2 0 0 0 2 -2"})]}),D),Rg=w(T("g",{stroke:"currentColor",fill:"none",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M11.217 19.384a3.501 3.501 0 0 0 6.783 -1.217v-5.167l-6 -3.35"}),c("path",{d:"M5.214 15.014a3.501 3.501 0 0 0 4.446 5.266l4.34 -2.534v-6.946"}),c("path",{d:"M6 7.63c-1.391 -.236 -2.787 .395 -3.534 1.689a3.474 3.474 0 0 0 1.271 4.745l4.263 2.514l6 -3.348"}),c("path",{d:"M12.783 4.616a3.501 3.501 0 0 0 -6.783 1.217v5.067l6 3.45"}),c("path",{d:"M18.786 8.986a3.501 3.501 0 0 0 -4.446 -5.266l-4.34 2.534v6.946"}),c("path",{d:"M18 16.302c1.391 .236 2.787 -.395 3.534 -1.689a3.474 3.474 0 0 0 -1.271 -4.745l-4.308 -2.514l-5.955 3.42"})]}),D),Tg=w(T("g",{stroke:"currentColor",fill:"none",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 8v-2a2 2 0 0 1 2 -2h2"}),c("path",{d:"M4 16v2a2 2 0 0 0 2 2h2"}),c("path",{d:"M16 4h2a2 2 0 0 1 2 2v2"}),c("path",{d:"M16 20h2a2 2 0 0 0 2 -2v-2"})]}),D),Lg=w(T("g",{stroke:"currentColor",fill:"none",strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M10 12a2 2 0 1 0 4 0a2 2 0 0 0 -4 0"}),c("path",{d:"M21 12c-2.4 4 -5.4 6 -9 6c-3.6 0 -6.6 -2 -9 -6c2.4 -4 5.4 -6 9 -6c3.6 0 6.6 2 9 6"})]}),D),Mg=w(T("g",{stroke:"currentColor",fill:"none",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M10.585 10.587a2 2 0 0 0 2.829 2.828"}),c("path",{d:"M16.681 16.673a8.717 8.717 0 0 1 -4.681 1.327c-3.6 0 -6.6 -2 -9 -6c1.272 -2.12 2.712 -3.678 4.32 -4.674m2.86 -1.146a9.055 9.055 0 0 1 1.82 -.18c3.6 0 6.6 2 9 6c-.666 1.11 -1.379 2.067 -2.138 2.87"}),c("path",{d:"M3 3l18 18"})]}),D),$g=w(T("g",{stroke:"currentColor",fill:"none",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M15.5 13a3.5 3.5 0 0 0 -3.5 3.5v1a3.5 3.5 0 0 0 7 0v-1.8"}),c("path",{d:"M8.5 13a3.5 3.5 0 0 1 3.5 3.5v1a3.5 3.5 0 0 1 -7 0v-1.8"}),c("path",{d:"M17.5 16a3.5 3.5 0 0 0 0 -7h-.5"}),c("path",{d:"M19 9.3v-2.8a3.5 3.5 0 0 0 -7 0"}),c("path",{d:"M6.5 16a3.5 3.5 0 0 1 0 -7h.5"}),c("path",{d:"M5 9.3v-2.8a3.5 3.5 0 0 1 7 0v10"})]}),D),Dg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M15.5 13a3.5 3.5 0 0 0 -3.5 3.5v1a3.5 3.5 0 0 0 7 0v-1.8"}),c("path",{d:"M8.5 13a3.5 3.5 0 0 1 3.5 3.5v1a3.5 3.5 0 0 1 -7 0v-1.8"}),c("path",{d:"M17.5 16a3.5 3.5 0 0 0 0 -7h-.5"}),c("path",{d:"M19 9.3v-2.8a3.5 3.5 0 0 0 -7 0"}),c("path",{d:"M6.5 16a3.5 3.5 0 0 1 0 -7h.5"}),c("path",{d:"M5 9.3v-2.8a3.5 3.5 0 0 1 7 0v10"})]}),D),vg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0"}),c("path",{d:"M21 21l-6 -6"})]}),D),Ng=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M20.984 12.53a9 9 0 1 0 -7.552 8.355"}),c("path",{d:"M12 7v5l3 3"}),c("path",{d:"M19 16l-2 3h4l-2 3"})]}),D),Fg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M9 2m0 3a3 3 0 0 1 3 -3h0a3 3 0 0 1 3 3v5a3 3 0 0 1 -3 3h0a3 3 0 0 1 -3 -3z"}),c("path",{d:"M5 10a7 7 0 0 0 14 0"}),c("path",{d:"M8 21l8 0"}),c("path",{d:"M12 17l0 4"})]}),D),Sg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 3l18 18"}),c("path",{d:"M9 5a3 3 0 0 1 6 0v5a3 3 0 0 1 -.13 .874m-2 2a3 3 0 0 1 -3.87 -2.872v-1"}),c("path",{d:"M5 10a7 7 0 0 0 10.846 5.85m2 -2a6.967 6.967 0 0 0 1.152 -3.85"}),c("path",{d:"M8 21l8 0"}),c("path",{d:"M12 17l0 4"})]}),D),Pg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M13 3l0 7l6 0l-8 11l0 -7l-6 0l8 -11"})]}),D),_g=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M8 8m0 1a1 1 0 0 1 1 -1h6a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-6a1 1 0 0 1 -1 -1z"}),c("path",{d:"M12 20v.01"}),c("path",{d:"M16 20v.01"}),c("path",{d:"M8 20v.01"}),c("path",{d:"M4 20v.01"}),c("path",{d:"M4 16v.01"}),c("path",{d:"M4 12v.01"}),c("path",{d:"M4 8v.01"}),c("path",{d:"M4 4v.01"}),c("path",{d:"M8 4v.01"}),c("path",{d:"M12 4v.01"}),c("path",{d:"M16 4v.01"}),c("path",{d:"M20 4v.01"}),c("path",{d:"M20 8v.01"}),c("path",{d:"M20 12v.01"}),c("path",{d:"M20 16v.01"}),c("path",{d:"M20 20v.01"})]}),D),Bg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M5 3v18"}),c("path",{d:"M19 21v-18"}),c("path",{d:"M5 7h14"}),c("path",{d:"M5 15h14"}),c("path",{d:"M8 13v4"}),c("path",{d:"M11 13v4"}),c("path",{d:"M16 13v4"}),c("path",{d:"M14 5v4"}),c("path",{d:"M11 5v4"}),c("path",{d:"M8 5v4"}),c("path",{d:"M3 21h18"})]}),D),Og=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 12l18 0"}),c("path",{d:"M7 16l10 0l-10 5l0 -5"}),c("path",{d:"M7 8l10 0l-10 -5l0 5"})]}),D),Kg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M12 3l0 18"}),c("path",{d:"M16 7l0 10l5 0l-5 -10"}),c("path",{d:"M8 7l0 10l-5 0l5 -10"})]}),D),Jg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M5 3m0 2a2 2 0 0 1 2 -2h10a2 2 0 0 1 2 2v2a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2z"}),c("path",{d:"M19 6h1a2 2 0 0 1 2 2a5 5 0 0 1 -5 5l-5 0v2"}),c("path",{d:"M10 15m0 1a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1z"})]}),D),Hg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M15 15m-5 0a5 5 0 1 0 10 0a5 5 0 1 0 -10 0"}),c("path",{d:"M22 22l-3 -3"}),c("path",{d:"M6 18h-1a2 2 0 0 1 -2 -2v-1"}),c("path",{d:"M3 11v-1"}),c("path",{d:"M3 6v-1a2 2 0 0 1 2 -2h1"}),c("path",{d:"M10 3h1"}),c("path",{d:"M15 3h1a2 2 0 0 1 2 2v1"})]}),D),Yg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M14 3v4a1 1 0 0 0 1 1h4"}),c("path",{d:"M5 12v-7a2 2 0 0 1 2 -2h7l5 5v4"}),c("path",{d:"M4 20.25c0 .414 .336 .75 .75 .75h1.25a1 1 0 0 0 1 -1v-1a1 1 0 0 0 -1 -1h-1a1 1 0 0 1 -1 -1v-1a1 1 0 0 1 1 -1h1.25a.75 .75 0 0 1 .75 .75"}),c("path",{d:"M10 15l2 6l2 -6"}),c("path",{d:"M20 15h-1a2 2 0 0 0 -2 2v2a2 2 0 0 0 2 2h1v-3"})]}),D),Ag=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M14 3v4a1 1 0 0 0 1 1h4"}),c("path",{d:"M5 12v-7a2 2 0 0 1 2 -2h7l5 5v4"}),c("path",{d:"M20 15h-1a2 2 0 0 0 -2 2v2a2 2 0 0 0 2 2h1v-3"}),c("path",{d:"M5 18h1.5a1.5 1.5 0 0 0 0 -3h-1.5v6"}),c("path",{d:"M11 21v-6l3 6v-6"})]}),D),Vg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4 13v-8a2 2 0 0 1 2 -2h1a2 2 0 0 1 2 2v8a2 2 0 0 0 6 0v-8a2 2 0 0 1 2 -2h1a2 2 0 0 1 2 2v8a8 8 0 0 1 -16 0"}),c("path",{d:"M4 8l5 0"}),c("path",{d:"M15 8l4 0"})]}),D),qg=w(T("g",{strokeWidth:1.25,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 14c.83 .642 2.077 1.017 3.5 1c1.423 .017 2.67 -.358 3.5 -1c.83 -.642 2.077 -1.017 3.5 -1c1.423 -.017 2.67 .358 3.5 1"}),c("path",{d:"M8 3a2.4 2.4 0 0 0 -1 2a2.4 2.4 0 0 0 1 2"}),c("path",{d:"M12 3a2.4 2.4 0 0 0 -1 2a2.4 2.4 0 0 0 1 2"}),c("path",{d:"M3 10h14v5a6 6 0 0 1 -6 6h-2a6 6 0 0 1 -6 -6v-5z"}),c("path",{d:"M16.746 16.726a3 3 0 1 0 .252 -5.555"})]}),D),Cg=w(T("g",{stroke:"currentColor",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 5a1 1 0 0 1 1-1h16a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1h-16a1 1 0 0 1-1-1v-10zM7 20h10M9 16v4M15 16v4"})]}),{...D,strokeWidth:1.5}),Xg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M15 8v-2a2 2 0 0 0 -2 -2h-7a2 2 0 0 0 -2 2v12a2 2 0 0 0 2 2h7a2 2 0 0 0 2 -2v-2"}),c("path",{d:"M21 12h-13l3 -3"}),c("path",{d:"M11 15l-3 -3"})]}),D),Gg=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M2 8a4 4 0 0 1 4 -4h12a4 4 0 0 1 4 4v8a4 4 0 0 1 -4 4h-12a4 4 0 0 1 -4 -4v-8z"}),c("path",{d:"M10 9l5 3l-5 3z"})]}),D),Zg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M3 6h18"}),c("path",{d:"M3 12h18"}),c("path",{d:"M3 18h18"}),c("path",{d:"M6 3v18"}),c("path",{d:"M12 3v18"}),c("path",{d:"M18 3v18"})]}),D),kg=w(T("g",{strokeWidth:1.5,children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M17 3m0 1a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1z"}),c("path",{d:"M3 17m0 1a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1z"}),c("path",{d:"M17 5c-6.627 0 -12 5.373 -12 12"})]}),D),Wg=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M6 18l12 -12"}),c("path",{d:"M18 10v-4h-4"})]}),D),Qg=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M4,19L10,19C11.097,19 12,18.097 12,17L12,9C12,7.903 12.903,7 14,7L21,7"}),c("path",{d:"M18 4l3 3l-3 3"})]}),D),zg=w(T("g",{children:[c("path",{d:"M16,12L20,9L16,6"}),c("path",{d:"M6 20c0 -6.075 4.925 -11 11 -11h3"})]}),D),jg=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M6 9l6 6l6 -6"})]}),D),ex=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M6 15l6 -6l6 6"})]}),D),tx=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M6 15l6 -6l6 6"})]}),D),nx=w(T("g",{strokeWidth:"1.25",children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M8 5v10a1 1 0 0 0 1 1h10"}),c("path",{d:"M5 8h10a1 1 0 0 1 1 1v10"})]}),D),rx=w(T("g",{children:[c("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c("path",{d:"M5 5m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"}),c("path",{d:"M19 5m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"}),c("path",{d:"M5 19m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"}),c("path",{d:"M19 19m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"}),c("path",{d:"M5 7l0 10"}),c("path",{d:"M7 5l10 0"}),c("path",{d:"M7 19l10 0"}),c("path",{d:"M19 7l0 10"})]}),D),ox=w(T("g",{strokeWidth:"1.25",children:[c("rect",{x:"4",y:"4",width:"4",height:"4",rx:"1"}),c("rect",{x:"10",y:"4",width:"4",height:"4",rx:"1"}),c("rect",{x:"16",y:"4",width:"4",height:"4",rx:"1"}),c("rect",{x:"4",y:"10",width:"4",height:"4",rx:"1"}),c("rect",{x:"10",y:"10",width:"4",height:"4",rx:"1"}),c("rect",{x:"16",y:"10",width:"4",height:"4",rx:"1"}),c("rect",{x:"4",y:"16",width:"4",height:"4",rx:"1"}),c("rect",{x:"10",y:"16",width:"4",height:"4",rx:"1"}),c("rect",{x:"16",y:"16",width:"4",height:"4",rx:"1"})]}),D),ix=w(c("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:.5,viewBox:"0 0 640 512",children:c("path",{d:"M15 15C24.4 5.7 39.6 5.7 49 15l63 63L112 40c0-13.3 10.7-24 24-24s24 10.7 24 24l0 96c0 13.3-10.7 24-24 24l-96 0c-13.3 0-24-10.7-24-24s10.7-24 24-24l38.1 0L15 49C5.7 39.6 5.7 24.4 15 15zM133.5 243.9C158.6 193.6 222.7 112 320 112s161.4 81.6 186.5 131.9c3.8 7.6 3.8 16.5 0 24.2C481.4 318.4 417.3 400 320 400s-161.4-81.6-186.5-131.9c-3.8-7.6-3.8-16.5 0-24.2zM320 320a64 64 0 1 0 0-128 64 64 0 1 0 0 128zM591 15c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9l-63 63 38.1 0c13.3 0 24 10.7 24 24s-10.7 24-24 24l-96 0c-13.3 0-24-10.7-24-24l0-96c0-13.3 10.7-24 24-24s24 10.7 24 24l0 38.1 63-63zM15 497c-9.4-9.4-9.4-24.6 0-33.9l63-63L40 400c-13.3 0-24-10.7-24-24s10.7-24 24-24l96 0c13.3 0 24 10.7 24 24l0 96c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-38.1L49 497c-9.4 9.4-24.6 9.4-33.9 0zm576 0l-63-63 0 38.1c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-96c0-13.3 10.7-24 24-24l96 0c13.3 0 24 10.7 24 24s-10.7 24-24 24l-38.1 0 63 63c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0z"})}),D);function Br(e,t,n){return{center:e,halfWidth:t,halfHeight:n}}var Us=(e,t)=>{let{halfWidth:n,halfHeight:r,center:o}=t,i=n,a=r,s=Ge(M(e),G(M(o),-1)),d=Math.abs(s[0]),U=Math.abs(s[1]),l=.707,f=.707;for(let m=0;m<3;m++){let E=i*l,g=a*f,y=(i*i-a*a)*l**3/i,x=(a*a-i*i)*f**3/a,h=E-y,R=g-x,I=d-y,v=U-x,P=Math.hypot(R,h),S=Math.hypot(v,I);l=Math.min(1,Math.max(0,(I*P/S+y)/i)),f=Math.min(1,Math.max(0,(v*P/S+x)/a));let F=Math.hypot(f,l);l/=F,f/=F}let[p,b]=[i*l*Math.sign(s[0]),a*f*Math.sign(s[1])];return Q(H(s),u(p,b))};function ls({center:e,halfWidth:t,halfHeight:n},[r,o]){let[i,a]=e,s=r[0]-i,d=r[1]-a,U=o[0]-i,l=o[1]-a,f=Math.pow(U-s,2)/Math.pow(t,2)+Math.pow(l-d,2)/Math.pow(n,2),p=2*(s*(U-s)/Math.pow(t,2)+d*(l-d)/Math.pow(n,2)),b=Math.pow(s,2)/Math.pow(t,2)+Math.pow(d,2)/Math.pow(n,2)-1,m=(-p+Math.sqrt(Math.pow(p,2)-4*f*b))/(2*f),E=(-p-Math.sqrt(Math.pow(p,2)-4*f*b))/(2*f),g=[u(s+m*(U-s)+i,d+m*(l-d)+a),u(s+E*(U-s)+i,d+E*(l-d)+a)].filter(y=>!isNaN(y[0])&&!isNaN(y[1]));return g.length===2&&Re(g[0],g[1])?[g[0]]:g}var qn=(e,t,n=0)=>{switch(t.type){case"polygon":return Ra(e,t.data,n);case"ellipse":return qa(e,t.data,n);case"line":return jt(e,t.data,n);case"polyline":return ps(e,t.data,n);case"curve":return fs(e,t.data,n);case"polycurve":return K6(e,t.data,n);default:throw Error(`shape ${t} is not implemented`)}},Or=(e,t)=>{switch(t.type){case"polygon":return Ko(e,t.data);case"line":return!1;case"curve":return!1;case"ellipse":return Ca(e,t.data);case"polyline":{let n=bn(t.data.flat());return Ko(e,n)}case"polycurve":return!1;default:throw Error(`shape ${t} is not implemented`)}};var K6=(e,t,n)=>t.some(r=>fs(e,r,n)),J6=e=>{let[t,n,r,o]=e;return(i,a)=>Math.pow(1-i,3)*o[a]+3*i*Math.pow(1-i,2)*r[a]+3*Math.pow(i,2)*(1-i)*n[a]+t[a]*Math.pow(i,3)},H6=(e,t=10)=>{let n=J6(e),r=[n(0,0),n(0,1)],o=[],i=0,a=1/t;for(let s=0;s<t;s++)if(i+=a,i<=1){let d=u(n(i,0),n(i,1));o.push(B(r,d)),r=d}return o},fs=(e,t,n)=>ps(e,H6(t),n),ps=(e,t,n=1e-4)=>t.some(r=>jt(e,r,n));function xn(e,t=0){let n=Ve(Math.min(e.width,e.height),e);if(n<=0){let p=Jn(u(e.x-t,e.y-t),u(e.x+e.width+t,e.y+e.height+t)),b=B(u(p[0][0]+n,p[0][1]),u(p[1][0]-n,p[0][1])),m=B(u(p[1][0],p[0][1]+n),u(p[1][0],p[1][1]-n)),E=B(u(p[0][0]+n,p[1][1]),u(p[1][0]-n,p[1][1])),g=B(u(p[0][0],p[1][1]-n),u(p[0][0],p[0][1]+n));return[[b,m,E,g],[]]}let r=Ee(e),o=Jn(u(e.x,e.y),u(e.x+e.width,e.y+e.height)),i=B(u(o[0][0]+n,o[0][1]),u(o[1][0]-n,o[0][1])),a=B(u(o[1][0],o[0][1]+n),u(o[1][0],o[1][1]-n)),s=B(u(o[0][0]+n,o[1][1]),u(o[1][0]-n,o[1][1])),d=B(u(o[0][0],o[1][1]-n),u(o[0][0],o[0][1]+n)),U=[G(Le(M(u(o[0][0]-t,o[0][1]-t),r)),t),G(Le(M(u(o[1][0]+t,o[0][1]-t),r)),t),G(Le(M(u(o[1][0]+t,o[1][1]+t),r)),t),G(Le(M(u(o[0][0]-t,o[1][1]+t),r)),t)],l=[nt(H(U[0],d[1]),H(U[0],u(d[1][0]+2/3*(o[0][0]-d[1][0]),d[1][1]+2/3*(o[0][1]-d[1][1]))),H(U[0],u(i[0][0]+2/3*(o[0][0]-i[0][0]),i[0][1]+2/3*(o[0][1]-i[0][1]))),H(U[0],i[0])),nt(H(U[1],i[1]),H(U[1],u(i[1][0]+2/3*(o[1][0]-i[1][0]),i[1][1]+2/3*(o[0][1]-i[1][1]))),H(U[1],u(a[0][0]+2/3*(o[1][0]-a[0][0]),a[0][1]+2/3*(o[0][1]-a[0][1]))),H(U[1],a[0])),nt(H(U[2],a[1]),H(U[2],u(a[1][0]+2/3*(o[1][0]-a[1][0]),a[1][1]+2/3*(o[1][1]-a[1][1]))),H(U[2],u(s[1][0]+2/3*(o[1][0]-s[1][0]),s[1][1]+2/3*(o[1][1]-s[1][1]))),H(U[2],s[1])),nt(H(U[3],s[0]),H(U[3],u(s[0][0]+2/3*(o[0][0]-s[0][0]),s[0][1]+2/3*(o[1][1]-s[0][1]))),H(U[3],u(d[0][0]+2/3*(o[0][0]-d[0][0]),d[0][1]+2/3*(o[1][1]-d[0][1]))),H(U[3],d[0]))];return[[B(l[0][3],l[1][0]),B(l[1][3],l[2][0]),B(l[2][3],l[3][0]),B(l[3][3],l[0][0])],l]}function hn(e,t=0){let[n,r,o,i,a,s,d,U]=Kr(e),l=Ve(Math.abs(n-d),e),f=Ve(Math.abs(i-r),e);if(e.roundness?.type==null){let[R,I,v,P]=[u(e.x+n,e.y+r-t),u(e.x+o+t,e.y+i),u(e.x+a,e.y+s+t),u(e.x+d-t,e.y+U)],S=B(u(R[0]+l,R[1]+f),u(I[0]-l,I[1]-f)),F=B(u(I[0]-l,I[1]+f),u(v[0]+l,v[1]-f)),_=B(u(v[0]-l,v[1]-f),u(P[0]+l,P[1]+f)),O=B(u(P[0]+l,P[1]-f),u(R[0]-l,R[1]+f));return[[S,F,_,O],[]]}let p=Ee(e),[b,m,E,g]=[u(e.x+n,e.y+r),u(e.x+o,e.y+i),u(e.x+a,e.y+s),u(e.x+d,e.y+U)],y=[G(Le(M(m,p)),t),G(Le(M(E,p)),t),G(Le(M(g,p)),t),G(Le(M(b,p)),t)],x=[nt(H(y[0],u(m[0]-l,m[1]-f)),H(y[0],m),H(y[0],m),H(y[0],u(m[0]-l,m[1]+f))),nt(H(y[1],u(E[0]+l,E[1]-f)),H(y[1],E),H(y[1],E),H(y[1],u(E[0]-l,E[1]-f))),nt(H(y[2],u(g[0]+l,g[1]+f)),H(y[2],g),H(y[2],g),H(y[2],u(g[0]+l,g[1]-f))),nt(H(y[3],u(b[0]-l,b[1]+f)),H(y[3],b),H(y[3],b),H(y[3],u(b[0]+l,b[1]+f)))];return[[B(x[0][3],x[1][0]),B(x[1][3],x[2][0]),B(x[2][3],x[3][0]),B(x[3][3],x[0][0])],x]}var Jr=e=>{if(e.type==="arrow")return!1;let t=!ht(e.backgroundColor)||gn(e)||it(e)||z(e);return e.type==="line"?t&&ut(e.points):e.type==="freedraw"?t&&ut(e.points):t||mn(e)},Y6=({x:e,y:t,element:n,shape:r,threshold:o=10,frameNameBound:i=null})=>{let a=Jr(n)?Or(u(e,t),r)||qn(u(e,t),r,o):qn(u(e,t),r,o);return!a&&i&&(a=Or(u(e,t),{type:"polygon",data:Fr(i).data})),a},Go=(e,t,n,r,o=0)=>{let[i,a,s,d]=Be(n,r);return i-=o,a-=o,s+=o,d+=o,Tr(u(i,a),u(e,t),u(s,d))},Sx=(e,t)=>!Y6(e)&&!A6(e.x,e.y,us(e.element,t))&&Go(e.x,e.y,e.element,t),A6=(e,t,n)=>!!n&&Or(u(e,t),n),Hr=(e,t,n=0)=>{switch(e.type){case"rectangle":case"image":case"text":case"iframe":case"embeddable":case"frame":case"magicframe":return V6(e,t,n);case"diamond":return q6(e,t,n);case"ellipse":return C6(e,t,n);default:throw new Error(`Unimplemented element type '${e.type}'`)}},V6=(e,t,n=0)=>{let r=Ee(e),o=L(t[0],r,-e.angle),i=L(t[1],r,-e.angle),[a,s]=xn(e,n);return a.map(d=>_t(B(o,i),d)).filter(d=>d!=null).map(d=>L(d,r,e.angle)).concat(s.flatMap(d=>_o(d,B(o,i))).filter(d=>d!=null).map(d=>L(d,r,e.angle))).filter((d,U,l)=>l.findIndex(f=>Re(d,f))===U)},q6=(e,t,n=0)=>{let r=Ee(e),o=L(t[0],r,-e.angle),i=L(t[1],r,-e.angle),[a,s]=hn(e,n);return a.map(d=>_t(B(o,i),d)).filter(d=>d!=null).map(d=>L(d,r,e.angle)).concat(s.flatMap(d=>_o(d,B(o,i))).filter(d=>d!=null).map(d=>L(d,r,e.angle))).filter((d,U,l)=>l.findIndex(f=>Re(d,f))===U)},C6=(e,t,n=0)=>{let r=Ee(e),o=L(t[0],r,-e.angle),i=L(t[1],r,-e.angle);return ls(Br(r,e.width/2+n,e.height/2+n),Kn(o,i)).map(a=>L(a,r,e.angle))};import r8 from"lodash.throttle";var Cn={},bs=(e,t)=>{let n=Cn[e]||(Cn[e]={height:t});return n.height=t,n},Es=e=>{Cn[e]&&delete Cn[e]},Bx=e=>Cn[e]?.height??null;var yn=(e,t)=>{switch(e.type){case"rectangle":case"image":case"text":case"iframe":case"embeddable":case"frame":case"magicframe":return X6(e,t);case"diamond":return G6(e,t);case"ellipse":return Z6(e,t)}},X6=(e,t)=>{let n=Ee(e),r=L(t,n,-e.angle),[o,i]=xn(e);return Math.min(...o.map(a=>Lr(r,a)),...i.map(a=>Bo(a,r)).filter(a=>a!==null))},G6=(e,t)=>{let n=Ee(e),r=L(t,n,-e.angle),[o,i]=hn(e);return Math.min(...o.map(a=>Lr(r,a)),...i.map(a=>Bo(a,r)).filter(a=>a!==null))},Z6=(e,t)=>{let n=Ee(e);return Us(L(t,n,-e.angle),Br(n,e.width/2,e.height/2))};var Te=[1,0],Oe=[0,1],We=[-1,0],dt=[0,-1],wt=e=>{let[t,n]=e,r=Math.abs(t),o=Math.abs(n);return t>o?Te:t<=-o?We:n>r?Oe:dt},Ke=(e,t)=>wt(M(e,t)),ct=(e,t)=>qe(Ke(e,t)),ve=(e,t)=>e[0]===t[0]&&e[1]===t[1],qe=e=>ve(e,Te)||ve(e,We);var k6=(e,t,n)=>{let r=Xn(t);(rt()||$e())&&(be(e.width>0&&e.height>0,"Diamond element has no width or height"),be(!Re(r,n),"The point is too close to the element mid point to determine heading"));let o=.95,i=H(G(M(L(u(e.x+e.width/2,e.y),r,e.angle),r),o),r),a=H(G(M(L(u(e.x+e.width,e.y+e.height/2),r,e.angle),r),o),r),s=H(G(M(L(u(e.x+e.width/2,e.y+e.height),r,e.angle),r),o),r),d=H(G(M(L(u(e.x,e.y+e.height/2),r,e.angle),r),o),r);if(X(M(n,i),M(i,a))<=0&&X(M(n,i),M(i,d))>0)return Ke(i,r);if(X(M(n,a),M(a,s))<=0&&X(M(n,a),M(a,i))>0)return Ke(a,r);if(X(M(n,s),M(s,d))<=0&&X(M(n,s),M(s,a))>0)return Ke(s,r);if(X(M(n,d),M(d,i))<=0&&X(M(n,d),M(d,s))>0)return Ke(d,r);if(X(M(n,r),M(i,r))<=0&&X(M(n,r),M(a,r))>0){let l=e.width>e.height?i:a;return Ke(l,r)}else if(X(M(n,r),M(a,r))<=0&&X(M(n,r),M(s,r))>0){let l=e.width>e.height?s:a;return Ke(l,r)}else if(X(M(n,r),M(s,r))<=0&&X(M(n,r),M(d,r))>0){let l=e.width>e.height?s:d;return Ke(l,r)}let U=e.width>e.height?i:d;return Ke(U,r)},Zo=(e,t,n)=>{let o=Xn(t);if(e.type==="diamond")return k6(e,t,n);let i=zt(u(t[0],t[1]),o,2),a=zt(u(t[2],t[1]),o,2),s=zt(u(t[0],t[3]),o,2),d=zt(u(t[2],t[3]),o,2);return Mr([i,a,o],n)?dt:Mr([a,d,o],n)?Te:Mr([d,s,o],n)?Oe:We},ko=e=>[e[0]===0?0:e[0]>0?-1:1,e[1]===0?0:e[1]>0?-1:1];var ch=e=>!e[le.CTRL_OR_CMD],Wo=e=>e.isBindingEnabled,ce=5,xs=10,hs=4,W6=(e,t)=>{let n=[];return t.forEach(r=>{let o=e.getNonDeletedElement(r);o!=null&&n.push(o)}),n},Qo=(e,t,n,r,o)=>{let i=new Set,a=new Set;ms(e,t,n,"start",i,a,r),ms(e,n,t,"end",i,a,r);let s=Array.from(a).filter(d=>!i.has(d));W6(o,s).forEach(d=>{ee(d,{boundElements:d.boundElements?.filter(U=>U.type!=="arrow"||U.id!==e.id)})})},ms=(e,t,n,r,o,i,a)=>{if(t!=="keep"){if(t===null){let s=nf(e,r);s!=null&&i.add(s);return}ws(e)?(n==null||(n==="keep"?!Is(e,t,r):r==="start"||n.id!==t.id))&&(qr(e,t,r,a),o.add(t.id)):(qr(e,t,r,a),o.add(t.id))}},Q6=(e,t,n,r)=>{let o=Ms(e,t,n),i=t==="start"?e.startBinding?.elementId:e.endBinding?.elementId;if(i){let a=n.get(i);if(It(a)&&Yr(a,o,n,r))return a}return null},ys=(e,t,n)=>["start","end"].map(r=>Q6(e,r,t,n)),z6=(e,t,n,r,o,i)=>{let s=e.points.length-1,d=n.findIndex(p=>p===0)>-1,U=n.findIndex(p=>p===s)>-1,l=d?t?In(e,"start",r,o,i):null:q(e)?"keep":In(e,"start",r,o,i),f=U?t?In(e,"end",r,o,i):null:q(e)?"keep":In(e,"end",r,o,i);return[l,f]},j6=(e,t,n,r,o)=>{if(q(e))return["keep","keep"];let[i,a]=ys(e,t,o),s=i&&r?In(e,"start",t,n,o):null,d=a&&r?In(e,"end",t,n,o):null;return[s,d]},Uh=(e,t,n,r,o,i,a)=>{e.forEach(s=>{let[d,U]=i?.length?z6(s,o,i??[],t,n,a):j6(s,t,n,o,a);Qo(s,d,U,t,r)})},lh=(e,t,n)=>e.length>50?[]:e.filter(ge).flatMap(r=>ys(r,t,n)).filter(r=>r!==null).filter(r=>e.filter(o=>o.id===r?.id).length===0),fh=(e,t,n,r,o)=>{t.startBoundElement!=null&&qr(e,t.startBoundElement,"start",r);let i=rn(n,o,r,t.zoom,q(e),q(e));i!==null&&(Is(e,i,"end")||qr(e,i,"end",r))},ef=(e,t)=>{let n=e.gap,r=Wr(t,t.width,t.height);return n>r&&(n=xs+hs),{...e,gap:n}},qr=(e,t,n,r)=>{if(!j(e))return;let o={elementId:t.id,...ef(af(e,t,n,r),t)};q(e)&&(o={...o,...Ls(e,t,n,r)}),ee(e,{[n==="start"?"startBinding":"endBinding"]:o}),de(t.boundElements||[]).has(e.id)||ee(t,{boundElements:(t.boundElements||[]).concat({id:e.id,type:"arrow"})})},Is=(e,t,n)=>{let r=e[n==="start"?"endBinding":"startBinding"];return tf(e,r?.elementId,t)},tf=(e,t,n)=>t===n.id&&ws(e),ws=e=>e.points.length<3,nf=(e,t)=>{let n=t==="start"?"startBinding":"endBinding",r=e[n];return r==null?null:(ee(e,{[n]:null}),r.elementId)},rn=(e,t,n,r,o,i)=>{if(i){let s=!1,d=of(t,l=>It(l,!1)&&Yr(l,e,n,r,(o||!vr(l))&&!me(l))).filter(l=>s?!1:(vr(l)||(s=!0),!0));if(!d||d.length===0)return null;if(d.length===1)return d[0];let U=d.filter(l=>Yr(l,e,n,r,!1));return U.length===1?U[0]:d.sort((l,f)=>f.width**2+f.height**2-(l.width**2+l.height**2)).pop()}return rf(t,s=>It(s,!1)&&Yr(s,e,n,r,(o||!vr(s))&&!me(s)))},rf=(e,t)=>{let n=null;for(let r=e.length-1;r>=0;--r){let o=e[r];if(!o.isDeleted&&t(o)){n=o;break}}return n},of=(e,t)=>{let n=[];for(let r=e.length-1;r>=0;--r){let o=e[r];o.isDeleted||t(o)&&n.push(o)}return n},af=(e,t,n,r)=>{let o=n==="start"?-1:1,i=o===-1?0:e.points.length-1,a=i-o,s=W.getPointAtIndexGlobalCoordinates(e,i,r),d=W.getPointAtIndexGlobalCoordinates(e,a,r);return{focus:ff(t,d,s),gap:Math.max(1,yn(t,s))}},ph=(e,t,n)=>{let{newSize:r,simultaneouslyUpdated:o}=n??{},i=df(o);It(e)&&Cr(t,e,a=>{if(!ge(a)||a.isDeleted||!sf(a,e))return;let s=a.startBinding?t.get(a.startBinding.elementId):null,d=a.endBinding?t.get(a.endBinding.elementId):null,U=null,l=null;s&&d&&(U=Be(s,t),l=Be(d,t));let f={startBinding:gs(e,a.startBinding,r),endBinding:gs(e,a.endBinding,r)};if(i.has(a.id)){ee(a,f,!0);return}let p=Xr(t,a,(m,E)=>{if(m&&It(m)&&(E==="startBinding"||E==="endBinding")&&(e.id===a[E]?.elementId||e.id===a[E==="startBinding"?"endBinding":"startBinding"]?.elementId&&!$s(U,l))){let g=lf(a,E,f[E],m,t);if(g)return{index:E==="startBinding"?0:a.points.length-1,point:g}}return null}).filter(m=>m!==null);W.movePoints(a,p,{...e.id===a.startBinding?.elementId?{startBinding:f.startBinding}:{},...e.id===a.endBinding?.elementId?{endBinding:f.endBinding}:{}},t);let b=se(a,t);b&&!b.isDeleted&&Zr(a,t,!1)})},sf=(e,t)=>e.startBinding?.elementId===t.id||e.endBinding?.elementId===t.id,df=e=>new Set((e||[]).map(t=>t.id)),Rs=(e,t,n,r,o,i,a)=>{let s=wt(M(t,e));return!n||!r?s:cf(i,n,o,a)?Zo(n,r,e):wt(M(e,Ee(n)))},cf=(e,t,n,r)=>{let o=yn(t,e),i=Wr(t,t.width,t.height,r);return o>i?null:o},kr=(e,t,n)=>{(rt()||$e())&&be(e.points.length>1,"Arrow should have at least 2 points");let r=Ut(t),o=e.points[n==="start"?0:e.points.length-1],i=u(e.x+o[0],e.y+o[1]),a=Za(t)?Uf(t,i):i,s=q(e),d=Xn(r),U=n==="start"?1:e.points.length-2,l=L(u(e.x+e.points[U][0],e.y+e.points[U][1]),d,e.angle??0),f=null;if(s){let p=qe(Zo(t,r,i)),b=u(p?d[0]:a[0],p?a[1]:d[1]);f=Hr(t,B(b,H(G(Le(M(a,b)),Math.max(t.width,t.height)*2),b)))[0]}else f=Hr(t,B(l,H(G(Le(M(a,l)),Q(a,l)+Math.max(t.width,t.height)*2),l)),ce).sort((p,b)=>pt(p,l)-pt(b,l))[0];if(!f||pt(a,f)<1e-4)return a;if(s){let p=pt(a,d)-pt(f,d)>0?ce:-ce;return H(G(Le(M(a,f)),p),f)}return a},Uf=(e,t)=>{let n=Ee(e),r=L(t,n,-e.angle);return r[0]<e.x&&r[1]<e.y?r[1]-e.y>-ce?L(u(e.x-ce,e.y),n,e.angle):L(u(e.x,e.y-ce),n,e.angle):r[0]<e.x&&r[1]>e.y+e.height?r[0]-e.x>-ce?L(u(e.x,e.y+e.height+ce),n,e.angle):L(u(e.x-ce,e.y+e.height),n,e.angle):r[0]>e.x+e.width&&r[1]>e.y+e.height?r[0]-e.x<e.width+ce?L(u(e.x+e.width,e.y+e.height+ce),n,e.angle):L(u(e.x+e.width+ce,e.y+e.height),n,e.angle):r[0]>e.x+e.width&&r[1]<e.y?r[0]-e.x<e.width+ce?L(u(e.x+e.width,e.y-ce),n,e.angle):L(u(e.x+e.width+ce,e.y),n,e.angle):t},Ts=(e,t,n=.05)=>{let{x:r,y:o,width:i,height:a,angle:s}=e,d=Ee(e,-.1,-.1),U=L(t,d,-s),l=te(n*a,5,80),f=te(n*i,5,80);return U[0]<=r+i/2&&U[1]>d[1]-l&&U[1]<d[1]+l?L(u(r-ce,d[1]),d,s):U[1]<=o+a/2&&U[0]>d[0]-f&&U[0]<d[0]+f?L(u(d[0],o-ce),d,s):U[0]>=r+i/2&&U[1]>d[1]-l&&U[1]<d[1]+l?L(u(r+i+ce,d[1]),d,s):U[1]>=o+a/2&&U[0]>d[0]-f&&U[0]<d[0]+f?L(u(d[0],o+a+ce),d,s):t},lf=(e,t,n,r,o)=>{if(n==null||n.elementId!==r.id&&e.points.length>2)return null;let i=t==="startBinding"?-1:1,a=i===-1?0:e.points.length-1;if(q(e)&&nn(n)){let f=Zn(n.fixedPoint)??Ls(e,r,t==="startBinding"?"start":"end",o).fixedPoint,p=Ee(r),b=u(r.x+f[0]*r.width,r.y+f[1]*r.height),m=L(b,p,r.angle);return W.pointFromAbsoluteCoords(e,m,o)}let s=a-i,d=W.getPointAtIndexGlobalCoordinates(e,s,o),U=pf(r,n.focus,d),l;if(n.gap===0)l=U;else{let f=W.getPointAtIndexGlobalCoordinates(e,a,o),p=Ee(r),b=Q(d,f)+Q(d,p)+Math.max(r.width,r.height)*2,m=[...Hr(r,B(d,H(G(Le(M(U,d)),b),d)),n.gap).sort((E,g)=>pt(E,d)-pt(g,d)),H(G(Le(M(U,d)),Q(d,f)),d)];m.length>1?l=m[0]:m.length===1?l=U:l=f}return W.pointFromAbsoluteCoords(e,l,o)},Ls=(e,t,n,r)=>{let o=[t.x,t.y,t.x+t.width,t.y+t.height],i=kr(e,t,n),a=u(o[0]+(o[2]-o[0])/2,o[1]+(o[3]-o[1])/2),s=L(i,a,-t.angle);return{fixedPoint:Zn([(s[0]-t.x)/t.width,(s[1]-t.y)/t.height])}},gs=(e,t,n)=>{if(t==null||n==null)return t;let{width:r,height:o}=n,{width:i,height:a}=e,s=Math.max(1,Math.min(Wr(e,r,o),t.gap*(r<o?r/i:o/a)));return{...t,gap:s}},In=(e,t,n,r,o)=>rn(Ms(e,t,n),r,n,o,q(e),q(e)),Ms=(e,t,n)=>{let r=t==="start"?0:-1;return Ot(W.getPointAtIndexGlobalCoordinates(e,r,n))},uh=(e,t,n)=>{for(let r of e){if("boundElements"in r&&r.boundElements&&Object.assign(r,{boundElements:r.boundElements.reduce((o,i)=>{let a=t.get(i.id);return a&&o.push({...i,id:a}),o},[])}),"containerId"in r&&r.containerId&&Object.assign(r,{containerId:t.get(r.containerId)??null}),"endBinding"in r&&r.endBinding){let o=t.get(r.endBinding.elementId);Object.assign(r,{endBinding:o?{...r.endBinding,elementId:o}:null})}if("startBinding"in r&&r.startBinding){let o=t.get(r.startBinding.elementId);Object.assign(r,{startBinding:o?{...r.startBinding,elementId:o}:null})}q(r)&&Object.assign(r,Yt(r,n,{points:[r.points[0],r.points[r.points.length-1]]}))}},bh=(e,t)=>{let n=de(e);for(let r of t)Ar.unbindAffected(n,r,ee),Vr.unbindAffected(n,r,ee)},Gn=(e,t,n=[])=>{if(!e)return null;let r=e.filter(o=>!t.has(o.id));return r.push(...n.map(o=>({id:o.id,type:o.type}))),r},Yr=(e,{x:t,y:n},r,o,i)=>{let a=Wr(e,e.width,e.height,o),s=wn(e,r);return qn(u(t,n),s,a)||i===!0&&At(u(t,n),Ut(e))},Wr=(e,t,n,r)=>{let o=r?.value&&r.value<1?r.value:1,a=(e.type==="diamond"?1/Math.sqrt(2):1)*Math.min(t,n);return Math.max(16,Math.min(.25*a,32),xs/o+hs)},ff=(e,t,n)=>{let r=Ee(e);if(Re(t,n))return 0;let o=L(t,r,-e.angle),i=L(n,r,-e.angle),a=Math.sign(X(M(i,t),M(i,r)))*-1,s=B(i,H(G(Le(M(i,o)),Math.max(e.width*2,e.height*2)),i)),d=e.type==="diamond"?[B(u(e.x+e.width/2,e.y),u(e.x+e.width/2,e.y+e.height)),B(u(e.x,e.y+e.height/2),u(e.x+e.width,e.y+e.height/2))]:[B(u(e.x,e.y),u(e.x+e.width,e.y+e.height)),B(u(e.x+e.width,e.y),u(e.x,e.y+e.height))],U=e.type==="diamond"?[B(u(e.x+e.width/2,e.y-e.height),u(e.x+e.width/2,e.y+e.height*2)),B(u(e.x-e.width,e.y+e.height/2),u(e.x+e.width*2,e.y+e.height/2))]:[B(u(e.x-e.width,e.y-e.height),u(e.x+e.width*2,e.y+e.height*2)),B(u(e.x+e.width*2,e.y-e.height),u(e.x-e.width,e.y+e.height*2))];return[_t(s,U[0]),_t(s,U[1])].filter(p=>p!==null).sort((p,b)=>pt(p,n)-pt(b,n)).map((p,b)=>a*Q(r,p)/(e.type==="diamond"?Q(d[b][0],d[b][1])/2:Math.sqrt(e.width**2+e.height**2)/2)).sort((p,b)=>Math.abs(p)-Math.abs(b))[0]??0},pf=(e,t,n)=>{let r=Ee(e);if(t===0)return r;let o=(e.type==="diamond"?[u(e.x,e.y+e.height/2),u(e.x+e.width/2,e.y),u(e.x+e.width,e.y+e.height/2),u(e.x+e.width/2,e.y+e.height)]:[u(e.x,e.y),u(e.x+e.width,e.y),u(e.x+e.width,e.y+e.height),u(e.x,e.y+e.height)]).map(s=>H(G(M(s,r),Math.abs(t)),r)).map(s=>L(s,r,e.angle)),i=[X(M(n,o[0]),M(o[1],o[0]))>0&&(t>0?X(M(n,o[1]),M(o[2],o[1]))<0:X(M(n,o[3]),M(o[0],o[3]))<0),X(M(n,o[1]),M(o[2],o[1]))>0&&(t>0?X(M(n,o[2]),M(o[3],o[2]))<0:X(M(n,o[0]),M(o[1],o[0]))<0),X(M(n,o[2]),M(o[3],o[2]))>0&&(t>0?X(M(n,o[3]),M(o[0],o[3]))<0:X(M(n,o[1]),M(o[2],o[1]))<0),X(M(n,o[3]),M(o[0],o[3]))>0&&(t>0?X(M(n,o[0]),M(o[1],o[0]))<0:X(M(n,o[2]),M(o[3],o[2]))<0)];return i[0]?t>0?o[1]:o[0]:i[1]?t>0?o[2]:o[1]:i[2]?t>0?o[3]:o[2]:t>0?o[0]:o[3]},Eh=new Set(["boundElements","frameId","containerId","startBinding","endBinding"]),Cr=(e,t,n)=>{It(t)&&(t.boundElements?.slice()??[]).forEach(({id:o})=>{n(e.get(o),"boundElements",o)})},Xr=(e,t,n)=>{let r=[];if(t.frameId){let o=t.frameId;r.push(n(e.get(o),"frameId",o))}if(at(t)){let o=t.containerId;r.push(n(e.get(o),"containerId",o))}if(j(t)){if(t.startBinding){let o=t.startBinding.elementId;r.push(n(e.get(o),"startBinding",o))}if(t.endBinding){let o=t.endBinding.elementId;r.push(n(e.get(o),"endBinding",o))}}return r},Ar=class{static unbindAffected(t,n,r){n&&Xr(t,n,o=>{!o||o.isDeleted||Cr(t,o,(i,a,s)=>{s===n.id&&r(o,{boundElements:Gn(o.boundElements,new Set([s]))})})})}};N(Ar,"rebindAffected",(t,n,r)=>{!n||n.isDeleted||Xr(t,n,(o,i)=>{if(!o||o.isDeleted){r(n,{[i]:null});return}i!=="frameId"&&(o.boundElements?.find(a=>a.id===n.id)||(j(n)&&r(o,{boundElements:Gn(o.boundElements,new Set,new Array(n))}),z(n)&&(o.boundElements?.find(a=>a.type==="text")?r(n,{[i]:null}):r(o,{boundElements:Gn(o.boundElements,new Set,new Array(n))}))))})});var Vr=class{static unbindAffected(t,n,r){n&&Cr(t,n,o=>{!o||o.isDeleted||Xr(t,o,(i,a,s)=>{s===n.id&&r(o,{[a]:null})})})}};N(Vr,"rebindAffected",(t,n,r)=>{!n||n.isDeleted||Cr(t,n,(o,i,a)=>{if(!o||o.isDeleted){r(n,{boundElements:Gn(n.boundElements,new Set([a]))});return}z(o)&&((n.boundElements?.slice()??[]).reverse().find(d=>d.type==="text")?.id===o.id?o.containerId!==n.id&&r(o,{containerId:n.id}):(o.containerId!==null&&r(o,{containerId:null}),r(n,{boundElements:Gn(n.boundElements,new Set([o.id]))})))})});var Gr=(e,t)=>{let[n,r]=Zn(e);return L(u(t.x+t.width*n,t.y+t.height*r),Ee(t),t.angle)},uf=(e,t)=>{let n=e.startBinding&&t.get(e.startBinding.elementId),r=e.endBinding&&t.get(e.endBinding.elementId),o=n&&e.startBinding?Gr(e.startBinding.fixedPoint,n):u(e.x+e.points[0][0],e.y+e.points[0][1]),i=r&&e.endBinding?Gr(e.endBinding.fixedPoint,r):u(e.x+e.points[e.points.length-1][0],e.y+e.points[e.points.length-1][1]);return[o,i]},mh=(e,t)=>{let[n,r]=uf(e,t);return[W.pointFromAbsoluteCoords(e,n,t),W.pointFromAbsoluteCoords(e,r,t)]},Zn=e=>e&&(Math.abs(e[0]-.5)<1e-4||Math.abs(e[1]-.5)<1e-4)?e.map(t=>Math.abs(t-.5)<1e-4?.5001:t):e;var jo=1,ie=40,bf=(e,t)=>{let n=e.fixedSegments?e.fixedSegments.slice():null;if(n){let r=[];e.points.map(a=>u(e.x+a[0],e.y+a[1])).forEach((a,s,d)=>{if(s<2)return r.push(a);let U=Ke(a,d[s-1]),l=Ke(d[s-1],d[s-2]);if(ve(U,l)){let f=n?.findIndex(b=>b.index===s-1)??-1,p=n?.findIndex(b=>b.index===s)??-1;p!==-1&&(n[p].start=u(d[s-2][0]-e.x,d[s-2][1]-e.y)),f!==-1&&n.splice(f,1),r.splice(-1,1),n.forEach(b=>{b.index>s-1&&(b.index-=1)})}return r.push(a)});let o=[];r.forEach((a,s,d)=>{if(s<3)return o.push(a);if(Q(d[s-2],d[s-1])<jo){let U=n?.findIndex(p=>p.index===s-2)??-1,l=n?.findIndex(p=>p.index===s-1)??-1;l!==-1&&n.splice(l,1),U!==-1&&n.splice(U,1),o.splice(-2,2),n.forEach(p=>{p.index>s-2&&(p.index-=2)});let f=ct(a,d[s-1]);return o.push(u(f?a[0]:d[s-2][0],f?d[s-2][1]:a[1]))}o.push(a)});let i=n.filter(a=>a.index!==1&&a.index!==o.length-1);return i.length===0?Rt(ni(ri(ti(e,ei(e,t,o.map(a=>u(a[0]-e.x,a[1]-e.y))))??[])),i,null,null):(rt()&&be(jr(o),"Invalid elbow points with fixed segments"),Rt(o,i,e.startIsSpecial,e.endIsSpecial))}return{x:e.x,y:e.y,points:e.points,fixedSegments:e.fixedSegments,startIsSpecial:e.startIsSpecial,endIsSpecial:e.endIsSpecial}},Ef=(e,t,n)=>{let r=t.map(F=>F.index),i=(e.fixedSegments?.map(F=>F.index)??[]).findIndex(F=>!r.includes(F));if(i===-1||!e.fixedSegments?.[i])return{points:e.points};let a=e.fixedSegments[i].index,s=e.fixedSegments[i-1],d=e.fixedSegments[i+1],U=e.x+(s?s.end[0]:0),l=e.y+(s?s.end[1]:0),f=s?null:e.startBinding,p=d?null:e.endBinding,{startHeading:b,endHeading:m,startGlobalPoint:E,endGlobalPoint:g,hoveredStartElement:y,hoveredEndElement:x,...h}=ei({x:U,y:l,startBinding:f,endBinding:p,startArrowhead:null,endArrowhead:null,points:e.points},n,[u(0,0),u(e.x+(d?.start[0]??e.points[e.points.length-1][0])-U,e.y+(d?.start[1]??e.points[e.points.length-1][1])-l)],{isDragging:!1}),{points:R}=Rt(ni(ri(ti(e,{startHeading:b,endHeading:m,startGlobalPoint:E,endGlobalPoint:g,hoveredStartElement:y,hoveredEndElement:x,...h})??[])),t,null,null),I=[];if(s)for(let F=0;F<s.index;F++)I.push(u(e.x+e.points[F][0],e.y+e.points[F][1]));if(R.forEach(F=>{I.push(u(e.x+(s?s.end[0]:0)+F[0],e.y+(s?s.end[1]:0)+F[1]))}),d)for(let F=d.index;F<e.points.length;F++)I.push(u(e.x+e.points[F][0],e.y+e.points[F][1]));let v=(d?.index??e.points.length)-(s?.index??0)-1,P=t.map(F=>F.index>a?{...F,index:F.index-v+(R.length-1)}:F),S=I.flatMap((F,_)=>{let O=I[_-1],J=I[_+1];if(O&&J){let Pe=Ke(F,O),Ce=Ke(J,F);if(ve(Pe,Ce))return P.forEach(ne=>{ne.index>_&&(ne.index-=1)}),[];if(ve(Pe,ko(Ce)))return P.forEach(ne=>{ne.index>_&&(ne.index+=1)}),[F,F]}return[F]});return Rt(S,P,!1,!1)},mf=(e,t,n,r,o,i)=>{let a=t.map((I,v)=>e.fixedSegments==null||e.fixedSegments[v]===void 0||e.fixedSegments[v].index!==I.index||(I.start[0]!==e.fixedSegments[v].start[0]&&I.end[0]!==e.fixedSegments[v].end[0])!=(I.start[1]!==e.fixedSegments[v].start[1]&&I.end[1]!==e.fixedSegments[v].end[1])?v:null).filter(I=>I!==null).shift();if(a==null)return{points:e.points};let s=e.fixedSegments?.findIndex(I=>I.index===1)??-1,d=e.fixedSegments?.findIndex(I=>I.index===e.points.length-1)??-1,U=Q(t[a].start,t[a].end),l=U<ie+5;if(s===-1&&t[a].index===1&&o){let I=qe(n),P=(I?ve(n,Te):ve(n,Oe))?l?U/2:ie:l?-U/2:-ie;t[a].start=u(t[a].start[0]+(I?P:0),t[a].start[1]+(I?0:P))}if(d===-1&&t[a].index===e.points.length-1&&i){let I=qe(r),P=(I?ve(r,Te):ve(r,Oe))?l?U/2:ie:l?-U/2:-ie;t[a].end=u(t[a].end[0]+(I?P:0),t[a].end[1]+(I?0:P))}let f=t.map(I=>({...I,start:u(e.x+I.start[0],e.y+I.start[1]),end:u(e.x+I.end[0],e.y+I.end[1])})),p=e.points.map((I,v)=>u(e.x+I[0],e.y+I[1])),b=f[a].index-1,m=f[a].index,E=f[a].start,g=f[a].end,y=p[b-1]&&!Re(p[b],p[b-1])?ct(p[b-1],p[b]):void 0,x=p[m+1]&&!Re(p[m],p[m+1])?ct(p[m+1],p[m]):void 0;if(y!==void 0){let I=y?1:0;p[b-1][I]=E[I]}if(p[b]=E,p[m]=g,x!==void 0){let I=x?1:0;p[m+1][I]=g[I]}let h=f.findIndex(I=>I.index===b);if(h!==-1){let I=ct(f[h].end,f[h].start)?1:0;f[h].start[I]=E[I],f[h].end=E}let R=f.findIndex(I=>I.index===m+1);if(R!==-1){let I=ct(f[R].end,f[R].start)?1:0;f[R].end[I]=g[I],f[R].start=g}if(s===-1&&b===0){let I=o?qe(n):ct(p[1],p[0]);p.unshift(u(I?E[0]:e.x+e.points[0][0],I?e.y+e.points[0][1]:E[1])),o&&p.unshift(u(e.x+e.points[0][0],e.y+e.points[0][1]));for(let v of f)v.index+=o?2:1}if(d===-1&&m===e.points.length-1){let I=qe(r);p.push(u(I?g[0]:e.x+e.points[e.points.length-1][0],I?e.y+e.points[e.points.length-1][1]:g[1])),i&&p.push(u(e.x+e.points[e.points.length-1][0],e.y+e.points[e.points.length-1][1]))}return Rt(p,f.map(I=>({...I,start:u(I.start[0]-e.x,I.start[1]-e.y),end:u(I.end[0]-e.x,I.end[1]-e.y)})),!1,!1)},gf=(e,t,n,r,o,i,a,s,d)=>{let U=e.startIsSpecial??null,l=e.endIsSpecial??null,f=t.map((g,y)=>y===0?u(e.x+g[0],e.y+g[1]):y===t.length-1?u(e.x+g[0],e.y+g[1]):u(e.x+e.points[y][0],e.y+e.points[y][1])),p=n.map(g=>({...g,start:u(e.x+(g.start[0]-t[0][0]),e.y+(g.start[1]-t[0][1])),end:u(e.x+(g.end[0]-t[0][0]),e.y+(g.end[1]-t[0][1]))})),b=[],m=2+(U?1:0),E=2+(l?1:0);for(;b.length+m<f.length-E;)b.push(f[b.length+m]);{let g=f[U?2:1],y=f[U?3:2],x=qe(r),h=qe(wt(M(g,y)));if(s&&x===h){let R=x?ve(r,Te):ve(r,Oe);if(b.unshift(u(h?i[0]+(R?ie:-ie):y[0],h?y[1]:i[1]+(R?ie:-ie))),b.unshift(u(x?i[0]+(R?ie:-ie):i[0],x?i[1]:i[1]+(R?ie:-ie))),!U){U=!0;for(let I of p)I.index>1&&(I.index+=1)}}else if(b.unshift(u(h?i[0]:g[0],h?g[1]:i[1])),U){U=!1;for(let R of p)R.index>1&&(R.index-=1)}b.unshift(i)}{let g=f[f.length-(l?3:2)],y=f[f.length-(l?4:3)],x=qe(o),h=ct(y,g);if(d&&x===h){let R=x?ve(o,Te):ve(o,Oe);b.push(u(h?a[0]+(R?ie:-ie):y[0],h?y[1]:a[1]+(R?ie:-ie))),b.push(u(x?a[0]+(R?ie:-ie):a[0],x?a[1]:a[1]+(R?ie:-ie))),l||(l=!0)}else b.push(u(h?a[0]:g[0],h?g[1]:a[1])),l&&(l=!1)}return b.push(a),Rt(b,p.map(({index:g})=>({index:g,start:b[g-1],end:b[g]})).map(g=>({...g,start:u(g.start[0]-i[0],g.start[1]-i[1]),end:u(g.end[0]-i[0],g.end[1]-i[1])})),U,l)},Ue=1e6,Yt=(e,t,n,r)=>{if(e.points.length<2)return{points:n.points??e.points};(e.x<-Ue||e.x>Ue||e.y<-Ue||e.y>Ue||e.x+(n?.points?.[n?.points?.length-1]?.[0]??0)<-Ue||e.x+(n?.points?.[n?.points?.length-1]?.[0]??0)>Ue||e.y+(n?.points?.[n?.points?.length-1]?.[1]??0)<-Ue||e.y+(n?.points?.[n?.points?.length-1]?.[1]??0)>Ue||e.x+(e?.points?.[e?.points?.length-1]?.[0]??0)<-Ue||e.x+(e?.points?.[e?.points?.length-1]?.[0]??0)>Ue||e.y+(e?.points?.[e?.points?.length-1]?.[1]??0)<-Ue||e.y+(e?.points?.[e?.points?.length-1]?.[1]??0)>Ue)&&console.error("Elbow arrow (or update) is outside reasonable bounds (> 1e6)",{arrow:e,updates:n}),e.x=te(e.x,-Ue,Ue),e.y=te(e.y,-Ue,Ue),n.points&&(n.points=n.points.map(([I,v])=>u(te(I,-Ue,Ue),te(v,-Ue,Ue)))),$.PROD||(be(!n.points||n.points.length>=2,"Updated point array length must match the arrow point length, contain exactly the new start and end points or not be specified at all (i.e. you can't add new points between start and end manually to elbow arrows)"),be(!e.fixedSegments||e.fixedSegments.map(I=>I.start[0]===I.end[0]||I.start[1]===I.end[1]).every(Boolean),"Fixed segments must be either horizontal or vertical"),be(!n.fixedSegments||n.fixedSegments.map(I=>I.start[0]===I.end[0]||I.start[1]===I.end[1]).every(Boolean),"Updates to fixed segments must be either horizontal or vertical"),be(e.points.slice(1).map((I,v)=>I[0]===e.points[v][0]||I[1]===e.points[v][1]),"Elbow arrow segments must be either horizontal or vertical"));let o=n.fixedSegments??e.fixedSegments??[],i=n.points?n.points&&n.points.length===2?e.points.map((I,v)=>v===0?n.points[0]:v===e.points.length-1?n.points[1]:I):n.points.slice():e.points.slice(),{startBinding:a,endBinding:s,...d}=n,U=typeof a<"u"?a:e.startBinding,l=typeof s<"u"?s:e.endBinding,f=U&&zr(U.elementId,t),p=l&&zr(l.elementId,t),b=jr(i);if(U&&!f&&b||l&&!p&&b||t.size===0&&b||Object.keys(d).length===0&&(f?.id!==U?.elementId||p?.id!==l?.elementId))return Rt(i.map(I=>u(e.x+I[0],e.y+I[1])),e.fixedSegments,e.startIsSpecial,e.endIsSpecial);let{startHeading:m,endHeading:E,startGlobalPoint:g,endGlobalPoint:y,hoveredStartElement:x,hoveredEndElement:h,...R}=ei({x:e.x,y:e.y,startBinding:U,endBinding:l,startArrowhead:e.startArrowhead,endArrowhead:e.endArrowhead,points:e.points},t,i,r);return t.size===0&&b?Rt(i.map(I=>u(e.x+I[0],e.y+I[1])),e.fixedSegments,e.startIsSpecial,e.endIsSpecial):!n.points&&!n.fixedSegments&&!n.startBinding&&!n.endBinding?bf(e,t):n.startBinding===e.startBinding&&n.endBinding===e.endBinding&&(n.points??[]).every((I,v)=>Re(I,e.points[v]??u(1/0,1/0)))&&b?{}:o.length===0?Rt(ni(ri(ti(e,{startHeading:m,endHeading:E,startGlobalPoint:g,endGlobalPoint:y,hoveredStartElement:x,hoveredEndElement:h,...R})??[])),o,null,null):(e.fixedSegments?.length??0)>o.length?Ef(e,o,t):n.points?n.points&&n.fixedSegments?n:gf(e,i,o,m,E,g,y,x,h):mf(e,o,m,E,x,h)},ei=(e,t,n,r)=>{let o=On(n[0],Me(e.x,e.y)),i=On(n[n.length-1],Me(e.x,e.y)),a=null,s=null;if(r?.isDragging){let I=Array.from(t.values());a=Fs(o,t,I,r?.zoom)||null,s=Fs(i,t,I,r?.zoom)||null}else a=e.startBinding&&zr(e.startBinding.elementId,t)||null,s=e.endBinding&&zr(e.endBinding.elementId,t)||null;let d=vs({...e,type:"arrow",elbowed:!0,points:n},"start",e.startBinding?.fixedPoint,o,a,r?.isDragging),U=vs({...e,type:"arrow",elbowed:!0,points:n},"end",e.endBinding?.fixedPoint,i,s,r?.isDragging),l=Ns(d,U,t,a,o),f=Ns(U,d,t,s,i),p=[d[0]-2,d[1]-2,d[0]+2,d[1]+2],b=[U[0]-2,U[1]-2,U[0]+2,U[1]+2],m=a?Ut(a,Vt(l,e.startArrowhead?ce*6:ce*2,1)):p,E=s?Ut(s,Vt(f,e.endArrowhead?ce*6:ce*2,1)):b,g=At(d,s?Ut(s,Vt(f,ie,ie)):b)||At(U,a?Ut(a,Vt(l,ie,ie)):p),y=Ps(g?[p,b]:[m,E]),x=yf(g?p:m,g?b:E,y,g?Vt(l,!a&&!s?0:ie,0):Vt(l,!a&&!s?0:ie-(e.startArrowhead?ce*6:ce*2),ie),g?Vt(f,!a&&!s?0:ie,0):Vt(f,!a&&!s?0:ie-(e.endArrowhead?ce*6:ce*2),ie),g,a&&Ut(a),s&&Ut(s)),h=Ds(x[0],l,d),R=Ds(x[1],f,U);return{dynamicAABBs:x,startDonglePosition:h,startGlobalPoint:d,startHeading:l,endDonglePosition:R,endGlobalPoint:U,endHeading:f,commonBounds:y,hoveredStartElement:a,hoveredEndElement:s,boundsOverlap:g,startElementBounds:m,endElementBounds:E}},ti=(e,t)=>{let{dynamicAABBs:n,startDonglePosition:r,startGlobalPoint:o,startHeading:i,endDonglePosition:a,endGlobalPoint:s,endHeading:d,commonBounds:U,hoveredEndElement:l}=t,f=If(n,r||o,i,a||s,d,U),p=r&&Qr(r,f),b=a&&Qr(a,f),m=Qr(s,f);m&&l&&(m.closed=!0);let E=Qr(o,f);E&&e.startBinding&&(E.closed=!0);let g=p&&b&&(At(p.pos,n[1])||At(b.pos,n[0])),y=xf(p||E,b||m,f,i||Te,d||Te,g?[]:n);if(y){let x=y.map(h=>[h.pos[0],h.pos[1]]);return p&&x.unshift(o),b&&x.push(s),x}return null},Vt=(e,t,n)=>{switch(e){case dt:return[t,n,n,n];case Te:return[n,t,n,n];case Oe:return[n,n,t,n]}return[n,n,n,t]},xf=(e,t,n,r,o,i)=>{let a=zo(e.pos,t.pos),s=new dr(d=>d.f);for(s.push(e);s.size()>0;){let d=s.pop();if(!d||d.closed)continue;if(d===t)return hf(e,d);d.closed=!0;let U=Rf(d.addr,n);for(let l=0;l<4;l++){let f=U[l];if(!f||f.closed)continue;let p=zt(f.pos,d.pos,.5);if(Oa(...i.map(R=>At(p,R))))continue;let b=Tf(l),m=d.parent?wt(M(d.pos,d.parent.pos)):r,E=ko(m);if(ve(E,b)||Ss(e.addr,f.addr)&&ve(b,r)||Ss(t.addr,f.addr)&&ve(b,o))continue;let y=m!==b,x=d.g+zo(f.pos,d.pos)+(y?Math.pow(a,3):0),h=f.visited;if(!h||x<f.g){let R=wf(f,t,b,o);f.visited=!0,f.parent=d,f.h=zo(t.pos,f.pos)+R*Math.pow(a,2),f.g=x,f.f=f.g+f.h,h?s.rescoreElement(f):s.push(f)}}}return null},hf=(e,t)=>{let n=t,r=[];for(;n.parent;)r.unshift(n),n=n.parent;return r.unshift(e),r},zo=(e,t)=>Math.abs(e[0]-t[0])+Math.abs(e[1]-t[1]),yf=(e,t,n,r,o,i,a,s)=>{let d=a??e,U=s??t,[l,f,p,b]=r??[0,0,0,0],[m,E,g,y]=o??[0,0,0,0],x=[e[0]>t[2]?e[1]>t[3]||e[3]<t[1]?Math.min((d[0]+U[2])/2,e[0]-b):(d[0]+U[2])/2:e[0]>t[0]?e[0]-b:n[0]-b,e[1]>t[3]?e[0]>t[2]||e[2]<t[0]?Math.min((d[1]+U[3])/2,e[1]-l):(d[1]+U[3])/2:e[1]>t[1]?e[1]-l:n[1]-l,e[2]<t[0]?e[1]>t[3]||e[3]<t[1]?Math.max((d[2]+U[0])/2,e[2]+f):(d[2]+U[0])/2:e[2]<t[2]?e[2]+f:n[2]+f,e[3]<t[1]?e[0]>t[2]||e[2]<t[0]?Math.max((d[3]+U[1])/2,e[3]+p):(d[3]+U[1])/2:e[3]<t[3]?e[3]+p:n[3]+p],h=[t[0]>e[2]?t[1]>e[3]||t[3]<e[1]?Math.min((U[0]+d[2])/2,t[0]-y):(U[0]+d[2])/2:t[0]>e[0]?t[0]-y:n[0]-y,t[1]>e[3]?t[0]>e[2]||t[2]<e[0]?Math.min((U[1]+d[3])/2,t[1]-m):(U[1]+d[3])/2:t[1]>e[1]?t[1]-m:n[1]-m,t[2]<e[0]?t[1]>e[3]||t[3]<e[1]?Math.max((U[2]+d[0])/2,t[2]+E):(U[2]+d[0])/2:t[2]<e[2]?t[2]+E:n[2]+E,t[3]<e[1]?t[0]>e[2]||t[2]<e[0]?Math.max((U[3]+d[1])/2,t[3]+g):(U[3]+d[1])/2:t[3]<e[3]?t[3]+g:n[3]+g],R=Ps([x,h]);if(!i&&x[2]-x[0]+h[2]-h[0]>R[2]-R[0]+1e-11&&x[3]-x[1]+h[3]-h[1]>R[3]-R[1]+1e-11){let[I,v]=[(h[0]+h[2])/2,(h[1]+h[3])/2];if(t[0]>e[2]&&e[1]>t[3]){let P=x[2]+(h[0]-x[2])/2,S=h[3]+(x[1]-h[3])/2;return X(Me(e[2]-I,e[1]-v),Me(e[0]-I,e[3]-v))>0?[[x[0],x[1],P,x[3]],[P,h[1],h[2],h[3]]]:[[x[0],S,x[2],x[3]],[h[0],h[1],h[2],S]]}else if(e[2]<t[0]&&e[3]<t[1]){let P=x[2]+(h[0]-x[2])/2,S=x[3]+(h[1]-x[3])/2;return X(Me(e[0]-I,e[1]-v),Me(e[2]-I,e[3]-v))>0?[[x[0],x[1],x[2],S],[h[0],S,h[2],h[3]]]:[[x[0],x[1],P,x[3]],[P,h[1],h[2],h[3]]]}else if(e[0]>t[2]&&e[3]<t[1]){let P=h[2]+(x[0]-h[2])/2,S=x[3]+(h[1]-x[3])/2;return X(Me(e[2]-I,e[1]-v),Me(e[0]-I,e[3]-v))>0?[[P,x[1],x[2],x[3]],[h[0],h[1],P,h[3]]]:[[x[0],x[1],x[2],S],[h[0],S,h[2],h[3]]]}else if(e[0]>t[2]&&e[1]>t[3]){let P=h[2]+(x[0]-h[2])/2,S=h[3]+(x[1]-h[3])/2;return X(Me(e[0]-I,e[1]-v),Me(e[2]-I,e[3]-v))>0?[[P,x[1],x[2],x[3]],[h[0],h[1],P,h[3]]]:[[x[0],S,x[2],x[3]],[h[0],h[1],h[2],S]]}}return[x,h]},If=(e,t,n,r,o,i)=>{let a=new Set,s=new Set;n===We||n===Te?s.add(t[1]):a.add(t[0]),o===We||o===Te?s.add(r[1]):a.add(r[0]),e.forEach(l=>{a.add(l[0]),a.add(l[2]),s.add(l[1]),s.add(l[3])}),a.add(i[0]),a.add(i[2]),s.add(i[1]),s.add(i[3]);let d=Array.from(s).sort((l,f)=>l-f),U=Array.from(a).sort((l,f)=>l-f);return{row:d.length,col:U.length,data:d.flatMap((l,f)=>U.map((p,b)=>({f:0,g:0,h:0,closed:!1,visited:!1,parent:null,addr:[b,f],pos:[p,l]})))}},Ds=(e,t,n)=>{switch(t){case dt:return u(n[0],e[1]);case Te:return u(e[2],n[1]);case Oe:return u(n[0],e[3])}return u(e[0],n[1])},wf=(e,t,n,r)=>{if(r===Te)switch(n){case Te:return e.pos[0]>=t.pos[0]?4:e.pos[1]===t.pos[1]?0:2;case dt:return e.pos[1]>t.pos[1]&&e.pos[0]<t.pos[0]?1:3;case Oe:return e.pos[1]<t.pos[1]&&e.pos[0]<t.pos[0]?1:3;case We:return e.pos[1]===t.pos[1]?4:2}else if(r===We)switch(n){case Te:return e.pos[1]===t.pos[1]?4:2;case dt:return e.pos[1]>t.pos[1]&&e.pos[0]>t.pos[0]?1:3;case Oe:return e.pos[1]<t.pos[1]&&e.pos[0]>t.pos[0]?1:3;case We:return e.pos[0]<=t.pos[0]?4:e.pos[1]===t.pos[1]?0:2}else if(r===dt)switch(n){case Te:return e.pos[1]>t.pos[1]&&e.pos[0]<t.pos[0]?1:3;case dt:return e.pos[1]>=t.pos[1]?4:e.pos[0]===t.pos[0]?0:2;case Oe:return e.pos[0]===t.pos[0]?4:2;case We:return e.pos[1]>t.pos[1]&&e.pos[0]>t.pos[0]?1:3}else if(r===Oe)switch(n){case Te:return e.pos[1]<t.pos[1]&&e.pos[0]<t.pos[0]?1:3;case dt:return e.pos[0]===t.pos[0]?4:2;case Oe:return e.pos[1]<=t.pos[1]?4:e.pos[0]===t.pos[0]?0:2;case We:return e.pos[1]<t.pos[1]&&e.pos[0]>t.pos[0]?1:3}return 0},Rf=([e,t],n)=>[kn([e,t-1],n),kn([e+1,t],n),kn([e,t+1],n),kn([e-1,t],n)],kn=([e,t],n)=>e<0||e>=n.col||t<0||t>=n.row?null:n.data[t*n.col+e]??null,Qr=(e,t)=>{for(let n=0;n<t.col;n++)for(let r=0;r<t.row;r++){let o=kn([n,r],t);if(o&&e[0]===o.pos[0]&&e[1]===o.pos[1])return o}return null},Ps=e=>[Math.min(...e.map(t=>t[0])),Math.min(...e.map(t=>t[1])),Math.max(...e.map(t=>t[2])),Math.max(...e.map(t=>t[3]))],zr=(e,t)=>{let n=t.get(e);return n&&It(n)?n:null},Rt=(e,t,n,r)=>{let o=e[0][0],i=e[0][1],a=e.map(s=>On(s,G(M(e[0]),-1)));return(o<-Ue||o>Ue||i<-Ue||i>Ue||o+a[a.length-1][0]<-Ue||i+a[a.length-1][0]>Ue||o+a[a.length-1][1]<-Ue||i+a[a.length-1][1]>Ue)&&console.error("Elbow arrow normalization is outside reasonable bounds (> 1e6)",{x:o,y:i,points:a,...Bt(a)}),a=a.map(([s,d])=>u(te(s,-1e6,1e6),te(d,-1e6,1e6))),{points:a,x:te(o,-1e6,1e6),y:te(i,-1e6,1e6),fixedSegments:(t?.length??0)>0?t:null,...Bt(a),startIsSpecial:n,endIsSpecial:r}},ni=e=>{if(e.length>1){let t=Math.abs(e[0][1]-e[1][1])<Math.abs(e[0][0]-e[1][0]);return e.filter((n,r)=>{if(r===0||r===e.length-1)return!0;let o=e[r+1],i=Math.abs(n[1]-o[1])<Math.abs(n[0]-o[0]);return t===i?(t=i,!1):(t=i,!0)})}return e},ri=e=>e.length>=4?e.filter((t,n)=>{if(n===0||n===e.length-1)return!0;let r=e[n-1];return Q(r,t)>jo}):e,Tf=e=>{switch(e){case 0:return dt;case 1:return Te;case 2:return Oe}return We},vs=(e,t,n,r,o,i)=>{if(i){if(o){let a=kr(e,o,t);return Ts(o,a)}return r}if(o){let a=Gr(n||[0,0],o);return Math.abs(yn(o,a)-ce)>.01?kr(e,o,t):a}return r},Ns=(e,t,n,r,o)=>Rs(e,t,r,r&&Ut(r,Array(4).fill(yn(r,e))),n,o),Fs=(e,t,n,r)=>rn(Ot(e),n,t,r,!0,!0),Ss=(e,t)=>e[0]===t[0]&&e[1]===t[1],jr=(e,t=jo)=>e.slice(1).map((n,r)=>Math.abs(n[0]-e[r][0])<t||Math.abs(n[1]-e[r][1])<t).every(Boolean);var ee=(e,t,n=!0,r)=>{let o=!1,{points:i,fixedSegments:a,fileId:s,startBinding:d,endBinding:U}=t;if(q(e)&&(Object.keys(t).length===0||typeof i<"u"||typeof a<"u"||typeof d<"u"||typeof U<"u")){let l=Ze(Wn.getScene(e)?.getNonDeletedElementsMap()??new Map);t={...t,angle:0,...Yt({...e,x:t.x||e.x,y:t.y||e.y},l,{fixedSegments:a,points:i,startBinding:d,endBinding:U},{isDragging:r?.isDragging})}}else typeof i<"u"&&(t={...Bt(i),...t});for(let l in t){let f=t[l];if(typeof f<"u"){if(e[l]===f&&(typeof f!="object"||f===null||l==="groupIds"||l==="scale"))continue;if(l==="scale"){let p=e[l],b=f;if(p[0]===b[0]&&p[1]===b[1])continue}else if(l==="points"){let p=e[l],b=f;if(p.length===b.length){let m=!1,E=p.length;for(;--E;){let g=p[E],y=b[E];if(g[0]!==y[0]||g[1]!==y[1]){m=!0;break}}if(!m)continue}}e[l]=f,o=!0}}return o&&((typeof t.height<"u"||typeof t.width<"u"||typeof s<"u"||typeof i<"u")&&fe.delete(e),e.version++,e.versionNonce=Jt(),e.updated=Kt(),n&&Wn.getScene(e)?.triggerUpdate()),e},Rn=(e,t,n=!1)=>{let r=!1;for(let o in t){let i=t[o];if(typeof i<"u"){if(e[o]===i&&(typeof i!="object"||i===null))continue;r=!0}}return!r&&!n?e:{...e,...t,updated:Kt(),version:e.version+1,versionNonce:Jt()}},Qn=(e,t)=>(e.version=(t??e.version)+1,e.versionNonce=Jt(),e.updated=Kt(),e);var Tt=(e,t,n)=>{let r=e.split(`
@@ -30,4 +30,4 @@ import{a as $}from"./chunk-5P7BZ5EW.js";import{d as N}from"./chunk-SRAX5OIU.js";
30
30
  `),intrinsicSize:{w:550,h:720},sandbox:{allowSameOrigin:n}};return Et.set(e,p),p}return Et.set(e,{link:e,intrinsicSize:o,type:r,sandbox:{allowSameOrigin:n}}),{link:e,intrinsicSize:o,type:r,sandbox:{allowSameOrigin:n}}},Io=e=>{let t;Pr(e)?t="IFrame element":t=!e.link||e?.link===""?"Empty Web-Embed":e.link;let n=Math.max(Math.min(e.width/2,e.width/t.length),e.width/30),r=pe.Helvetica,o=Ie({fontSize:n,fontFamily:r});return bo({x:e.x+e.width/2,y:e.y+e.height/2,strokeColor:e.strokeColor!=="transparent"?e.strokeColor:"black",backgroundColor:"transparent",fontFamily:r,fontSize:n,text:sn(t,o,e.width-20),textAlign:"center",verticalAlign:Wt.MIDDLE,angle:e.angle??0})},Qi=(e,t)=>{try{let{hostname:n}=new URL(e),r=n.replace(/^www\./,"");if(t instanceof Set){if(Wi.has(r))return r;let i=r.replace(/^([^.]+)/,"*");return Wi.has(i)?i:null}let o=t.replace(/^www\./,"");if(r===o)return o}catch{}return null},V_=e=>{let t=e.match(Eu);if(t&&t.length===2)return t[1];let n=e.match(xu);if(n&&n.length===2)return n[1];let r=e.match(bu);if(r&&r.length===2)return r[1];if(N2.test(e))return`https://giphy.com/embed/${N2.exec(e)[1]}`;let o=e.match(gu);return o&&o.length===2?o[1]:e},q_=(e,t)=>{if(!e)return!1;if(t!=null)if(typeof t=="function"){let n=t(e);if(typeof n=="boolean")return n}else{if(typeof t=="boolean")return t;if(t instanceof RegExp)return t.test(e);if(Array.isArray(t)){for(let n of t)if(n instanceof RegExp){if(e.match(n))return!0}else if(Qi(e,n))return!0;return!1}}return!!Qi(e,Wi)};var zi=document.createElement("img");zi.src=`data:${C.svg}, ${encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#1971c2" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-external-link"><path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"></path><polyline points="15 3 21 3 21 9"></polyline><line x1="10" y1="14" x2="21" y2="3"></line></svg>')}`;var ji=document.createElement("img");ji.src=`data:${C.svg}, ${encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#1971c2" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="icon icon-tabler icons-tabler-outline icon-tabler-arrow-big-right-line"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M12 9v-3.586a1 1 0 0 1 1.707 -.707l6.586 6.586a1 1 0 0 1 0 1.414l-6.586 6.586a1 1 0 0 1 -1.707 -.707v-3.586h-6v-6h6z" /><path d="M3 9v6" /></svg>')}`;var ea=([e,t,n,r],o,i)=>{let a=yd,s=a/i.zoom.value,d=a/i.zoom.value,U=a/i.zoom.value,l=(e+n)/2,f=(t+r)/2,p=(a-8)/(2*i.zoom.value),b=4/i.zoom.value,m=n+b-p,E=t-b-U+p,[g,y]=L(u(m+s/2,E+d/2),u(l,f),o);return[g-s/2,y-d/2,s,d]},hu=(e,t,n,[r,o])=>{let i=4/n.zoom.value,[a,s,d,U]=A(e,t),[l,f,p,b]=ea([a,s,d,U],e.angle,n);return r>l-i&&r<l+i+p&&o>f-i&&o<f+b+i},z_=(e,t,n,[r,o],i)=>!e.link||n.selectedElementIds[e.id]?!1:!i&&n.viewModeEnabled&&Go(r,o,e,t)?!0:hu(e,t,n,u(r,o));var nB=(e,t,n,r,o=!0)=>{e.beginPath(),e.arc(t,n,r,0,Math.PI*2),e.fill(),o&&e.stroke()},_2=(e,t)=>[e.width/t,e.height/t],B2=({canvas:e,scale:t,normalizedWidth:n,normalizedHeight:r,theme:o,isExporting:i,viewBackgroundColor:a})=>{let s=e.getContext("2d");return s.setTransform(1,0,0,1,0,0),s.scale(t,t),i&&o===Xe.DARK&&(s.filter=gr),typeof a=="string"?((a==="transparent"||a.length===5||a.length===9||/(hsla|rgba)\(/.test(a))&&s.clearRect(0,0,n,r),s.save(),s.fillStyle=a,s.fillRect(0,0,n,r),s.restore()):s.clearRect(0,0,n,r),s};var wo={Bold:"#dddddd",Regular:"#e5e5e5"},yu=(e,t,n,r,o,i,a,s)=>{let d=r%t-t,U=o%t-t,l=t*i.value,f=1/i.value;e.save(),i.value===1&&e.translate(d%1?0:.5,U%1?0:.5);for(let p=d;p<d+a+t*2;p+=t){let b=n>1&&Math.round(p-r)%(n*t)===0;if(!b&&l<10)continue;let m=Math.min(1/i.value,b?4:1);e.lineWidth=m;let E=[m*3,f+(m+f)];e.beginPath(),e.setLineDash(b?[]:E),e.strokeStyle=b?wo.Bold:wo.Regular,e.moveTo(p,U-t),e.lineTo(p,Math.ceil(U+s+t*2)),e.stroke()}for(let p=U;p<U+s+t*2;p+=t){let b=n>1&&Math.round(p-o)%(n*t)===0;if(!b&&l<10)continue;let m=Math.min(1/i.value,b?4:1);e.lineWidth=m;let E=[m*3,f+(m+f)];e.beginPath(),e.setLineDash(b?[]:E),e.strokeStyle=b?wo.Bold:wo.Regular,e.moveTo(d-t,p),e.lineTo(Math.ceil(d+a+t*2),p),e.stroke()}e.restore()},O2=(e,t,n,r)=>{t.translate(e.x+r.scrollX,e.y+r.scrollY),t.beginPath(),t.roundRect?t.roundRect(0,0,e.width,e.height,we.radius/r.zoom.value):t.rect(0,0,e.width,e.height),t.clip(),t.translate(-(e.x+r.scrollX),-(e.y+r.scrollY))},K2={regularLink:null,elementLink:null},J2=(e,t,n,r)=>{if(e.link&&!n.selectedElementIds[e.id]){let[o,i,a,s]=A(e,r),[d,U,l,f]=ea([o,i,a,s],e.angle,n),p=d+l/2,b=U+f/2;t.save(),t.translate(n.scrollX+p,n.scrollY+b),t.rotate(e.angle);let m=$2(e.link)?"elementLink":"regularLink",E=K2[m];if(!E||E.zoom!==n.zoom.value){E=Object.assign(document.createElement("canvas"),{zoom:n.zoom.value}),E.width=l*window.devicePixelRatio*n.zoom.value,E.height=f*window.devicePixelRatio*n.zoom.value,K2[m]=E;let g=E.getContext("2d");g.scale(window.devicePixelRatio*n.zoom.value,window.devicePixelRatio*n.zoom.value),g.fillStyle="#fff",g.fillRect(0,0,l,f),m==="elementLink"?g.drawImage(ji,0,0,l,f):g.drawImage(zi,0,0,l,f),g.restore()}t.drawImage(E,d-p,U-b,l,f),t.restore()}},H2=({canvas:e,rc:t,elementsMap:n,allElementsMap:r,visibleElements:o,scale:i,appState:a,renderConfig:s})=>{if(e===null)return;let{renderGrid:d=!0,isExporting:U}=s,[l,f]=_2(e,i),p=B2({canvas:e,scale:i,normalizedWidth:l,normalizedHeight:f,theme:a.theme,isExporting:U,viewBackgroundColor:a.viewBackgroundColor});p.scale(a.zoom.value,a.zoom.value),d&&yu(p,a.gridSize,a.gridStep,a.scrollX,a.scrollY,a.zoom,l/a.zoom.value,f/a.zoom.value);let b=new Set;o.forEach(E=>{E.groupIds.length>0&&a.frameToHighlight&&a.selectedElementIds[E.id]&&(Xt(E,a.frameToHighlight,n)||E.groupIds.find(g=>b.has(g)))&&E.groupIds.forEach(g=>b.add(g))});let m=new Map;o.filter(E=>!it(E)).forEach(E=>{try{let g=E.frameId||a.frameToHighlight?.id;if(z(E)&&E.containerId&&n.has(E.containerId))return;if(p.save(),g&&a.frameRendering.enabled&&a.frameRendering.clip){let x=oo(E,n,a);x&&gi(E,x,a,n,m)&&O2(x,p,s,a),Un(E,n,r,t,p,s,a)}else Un(E,n,r,t,p,s,a);let y=se(E,n);y&&Un(y,n,r,t,p,s,a),p.restore(),U||J2(E,p,a,n)}catch(g){console.error(g,E.id,E.x,E.y,E.width,E.height)}}),o.filter(E=>it(E)).forEach(E=>{try{let g=()=>{if(Un(E,n,r,t,p,s,a),it(E)&&(U||Sr(E)&&s.embedsValidationStatus.get(E.id)!==!0)&&E.width&&E.height){let x=Io(E);Un(x,n,r,t,p,s,a)}U||J2(E,p,a,n)};if((E.frameId||a.frameToHighlight?.id)&&a.frameRendering.enabled&&a.frameRendering.clip){p.save();let x=oo(E,n,a);x&&gi(E,x,a,n,m)&&O2(x,p,s,a),g(),p.restore()}else g()}catch(g){console.error(g)}}),s.pendingFlowchartNodes?.forEach(E=>{try{Un(E,n,r,t,p,s,a)}catch(g){console.error(g)}})},Iu=Da(e=>{H2(e)},{trailing:!0}),Y2=(e,t)=>{if(t){Iu(e);return}H2(e)};var ir=(e,t,n)=>{if(typeof n>"u")return e.draw(t);let r={sets:t.sets,shape:t.shape,options:{...t.options,fixedDecimalPlaceDigits:n}};return e.draw(r)},ar=(e,t,n,r,o)=>{if(!r.enabled||!r.clip)return null;let i=ze(e,o);if(i){let a=t.ownerDocument.createElementNS(k,"g");return a.setAttributeNS(k,"clip-path",`url(#${i.id})`),n.forEach(s=>a.appendChild(s)),a}return null},Ro=(e,t,n,r,o,i,a,s)=>{let d={x:i,y:a},[U,l,f,p]=A(e,t),b=(f-U)/2-(e.x-U),m=(p-l)/2-(e.y-l);if(z(e)){let h=Ne(e,t);if(j(h)){let[R,I,v,P]=A(h,t),S=W.getBoundTextElementPosition(h,e,t);b=(v-R)/2-(S.x-R),m=(P-I)/2-(S.y-I),i=i+S.x-e.x,a=a+S.y-e.y}}let E=180*e.angle/Math.PI,g=r;if(e.link){let h=r.ownerDocument.createElementNS(k,"a");h.setAttribute("href",yt(e.link)),g.appendChild(h),g=h}let y=(h,R)=>{$e()&&h.setAttribute("data-id",R.id),g.appendChild(h)},x=(ze(e,t)?.opacity??100)*e.opacity/1e4;switch(e.type){case"selection":throw new Error("Selection rendering is not supported for SVG");case"rectangle":case"diamond":case"ellipse":{let h=fe.generateElementShape(e,null),R=ir(n,h,fn);x!==1&&(R.setAttribute("stroke-opacity",`${x}`),R.setAttribute("fill-opacity",`${x}`)),R.setAttribute("stroke-linecap","round"),R.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`);let I=ar(e,g,[R],s.frameRendering,t);y(I||R,e);break}case"iframe":case"embeddable":{let h=fe.generateElementShape(e,s),R=ir(n,h,fn),I=e.opacity/100;I!==1&&(R.setAttribute("stroke-opacity",`${I}`),R.setAttribute("fill-opacity",`${I}`)),R.setAttribute("stroke-linecap","round"),R.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`),y(R,e);let v=Io(e);Ro(v,t,n,g,o,v.x+d.x-e.x,v.y+d.y-e.y,s);let P=ir(n,h,fn);for(P.setAttribute("stroke-linecap","round"),P.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`);P.firstChild;)P.removeChild(P.firstChild);let S=Ve(Math.min(e.width,e.height),e),F=P2(Ja(e.link||""));if(s.renderEmbeddables===!1||F?.type==="document"){let _=r.ownerDocument.createElementNS(k,"a");_.setAttribute("href",yt(e.link||"")),_.setAttribute("target","_blank"),_.setAttribute("rel","noopener noreferrer"),_.style.borderRadius=`${S}px`,P.appendChild(_)}else{let _=r.ownerDocument.createElementNS(k,"foreignObject");_.style.width=`${e.width}px`,_.style.height=`${e.height}px`,_.style.border="none";let O=_.ownerDocument.createElementNS(k,"div");O.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),O.style.width="100%",O.style.height="100%";let J=O.ownerDocument.createElement("iframe");J.src=F?.link??"",J.style.width="100%",J.style.height="100%",J.style.border="none",J.style.borderRadius=`${S}px`,J.style.top="0",J.style.left="0",J.allowFullscreen=!0,O.appendChild(J),_.appendChild(O),P.appendChild(_)}y(P,e);break}case"line":case"arrow":{let h=se(e,t),R=r.ownerDocument.createElementNS(k,"mask");if(h){R.setAttribute("id",`mask-${e.id}`);let S=r.ownerDocument.createElementNS(k,"rect");i=i||0,a=a||0,S.setAttribute("x","0"),S.setAttribute("y","0"),S.setAttribute("fill","#fff"),S.setAttribute("width",`${e.width+100+i}`),S.setAttribute("height",`${e.height+100+a}`),R.appendChild(S);let F=r.ownerDocument.createElementNS(k,"rect"),_=W.getBoundTextElementPosition(e,h,t),O=i+_.x-e.x,J=a+_.y-e.y;F.setAttribute("x",O.toString()),F.setAttribute("y",J.toString()),F.setAttribute("fill","#000"),F.setAttribute("width",`${h.width}`),F.setAttribute("height",`${h.height}`),F.setAttribute("opacity","1"),R.appendChild(F)}let I=r.ownerDocument.createElementNS(k,"g");h&&I.setAttribute("mask",`url(#mask-${e.id})`),I.setAttribute("stroke-linecap","round"),fe.generateElementShape(e,s).forEach(S=>{let F=ir(n,S,fn);x!==1&&(F.setAttribute("stroke-opacity",`${x}`),F.setAttribute("fill-opacity",`${x}`)),F.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`),e.type==="line"&&ut(e.points)&&e.backgroundColor!=="transparent"&&F.setAttribute("fill-rule","evenodd"),I.appendChild(F)});let P=ar(e,g,[I,R],s.frameRendering,t);P?(y(P,e),g.appendChild(P)):(y(I,e),g.append(R));break}case"freedraw":{let h=fe.generateElementShape(e,s),R=h?ir(n,h,fn):r.ownerDocument.createElementNS(k,"g");x!==1&&(R.setAttribute("stroke-opacity",`${x}`),R.setAttribute("fill-opacity",`${x}`)),R.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`),R.setAttribute("stroke","none");let I=r.ownerDocument.createElementNS(k,"path");I.setAttribute("fill",e.strokeColor),I.setAttribute("d",Ni(e)),R.appendChild(I);let v=ar(e,g,[R],s.frameRendering,t);y(v||R,e);break}case"image":{let h=Math.round(e.width),R=Math.round(e.height),I=Ht(e)&&o[e.fileId];if(I){let{reuseImages:v=!0}=s,P=`image-${I.id}`,S=e.width,F=e.height;e.crop&&({width:S,height:F}=Ln(e),P=`image-crop-${I.id}-${Od(`${S}x${F}`)}`),v||(P=`image-${e.id}`);let _=r.querySelector(`#${P}`);if(!_){_=r.ownerDocument.createElementNS(k,"symbol"),_.id=P;let ae=r.ownerDocument.createElementNS(k,"image");ae.setAttribute("href",I.dataURL),ae.setAttribute("preserveAspectRatio","none"),e.crop||!v?(ae.setAttribute("width",`${S}`),ae.setAttribute("height",`${F}`)):(ae.setAttribute("width","100%"),ae.setAttribute("height","100%")),_.appendChild(ae),(g.querySelector("defs")||g).prepend(_)}let O=r.ownerDocument.createElementNS(k,"use");O.setAttribute("href",`#${P}`),s.exportWithDarkMode&&I.mimeType!==C.svg&&O.setAttribute("filter",vi);let J=0,Pe=0;if(e.crop){let{width:ae,height:_e}=Ln(e);J=e.crop.x/(e.crop.naturalWidth/ae),Pe=e.crop.y/(e.crop.naturalHeight/_e)}let Ce=b+J,ne=m+Pe;O.setAttribute("width",`${h+J}`),O.setAttribute("height",`${R+Pe}`),O.setAttribute("opacity",`${x}`),(e.scale[0]!==1||e.scale[1]!==1)&&O.setAttribute("transform",`translate(${Ce} ${ne}) scale(${e.scale[0]} ${e.scale[1]}) translate(${-Ce} ${-ne})`);let he=r.ownerDocument.createElementNS(k,"g");if(e.crop){let ae=r.ownerDocument.createElementNS(k,"mask");ae.setAttribute("id",`mask-image-crop-${e.id}`),ae.setAttribute("fill","#fff");let _e=r.ownerDocument.createElementNS(k,"rect");_e.setAttribute("x",`${J}`),_e.setAttribute("y",`${Pe}`),_e.setAttribute("width",`${h}`),_e.setAttribute("height",`${R}`),ae.appendChild(_e),g.appendChild(ae),he.setAttribute("mask",`url(#${ae.id})`)}if(he.appendChild(O),he.setAttribute("transform",`translate(${i-J} ${a-Pe}) rotate(${E} ${Ce} ${ne})`),e.roundness){let ae=r.ownerDocument.createElementNS(k,"clipPath");ae.id=`image-clipPath-${e.id}`;let _e=r.ownerDocument.createElementNS(k,"rect"),mt=Ve(Math.min(e.width,e.height),e);_e.setAttribute("width",`${e.width}`),_e.setAttribute("height",`${e.height}`),_e.setAttribute("rx",`${mt}`),_e.setAttribute("ry",`${mt}`),ae.appendChild(_e),y(ae,e),he.setAttributeNS(k,"clip-path",`url(#${ae.id})`)}let je=ar(e,g,[he],s.frameRendering,t);y(je||he,e)}break}case"frame":case"magicframe":{if(s.frameRendering.enabled&&s.frameRendering.outline){let h=document.createElementNS(k,"rect");h.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`),h.setAttribute("width",`${e.width}px`),h.setAttribute("height",`${e.height}px`),h.setAttribute("rx",we.radius.toString()),h.setAttribute("ry",we.radius.toString()),h.setAttribute("fill","none"),h.setAttribute("stroke",we.strokeColor),h.setAttribute("stroke-width",we.strokeWidth.toString()),y(h,e)}break}default:if(z(e)){let h=r.ownerDocument.createElementNS(k,"g");x!==1&&(h.setAttribute("stroke-opacity",`${x}`),h.setAttribute("fill-opacity",`${x}`)),h.setAttribute("transform",`translate(${i||0} ${a||0}) rotate(${E} ${b} ${m})`);let R=e.text.replace(/\r\n?/g,`
31
31
  `).split(`
32
32
  `),I=Tn(e.fontSize,e.lineHeight),v=e.textAlign==="center"?e.width/2:e.textAlign==="right"?e.width:0,P=hr(e.fontFamily,e.fontSize,I),S=Dr(e.text)?"rtl":"ltr",F=e.textAlign==="center"?"middle":e.textAlign==="right"||S==="rtl"?"end":"start";for(let O=0;O<R.length;O++){let J=r.ownerDocument.createElementNS(k,"text");J.textContent=R[O],J.setAttribute("x",`${v}`),J.setAttribute("y",`${O*I+P}`),J.setAttribute("font-family",Yo(e)),J.setAttribute("font-size",`${e.fontSize}px`),J.setAttribute("fill",e.strokeColor),J.setAttribute("text-anchor",F),J.setAttribute("style","white-space: pre;"),J.setAttribute("direction",S),J.setAttribute("dominant-baseline","alphabetic"),h.appendChild(J)}let _=ar(e,g,[h],s.frameRendering,t);y(_||h,e)}else throw new Error(`Unimplemented type ${e.type}`)}},A2=(e,t,n,r,o,i)=>{r&&(e.filter(a=>!it(a)).forEach(a=>{if(!a.isDeleted){if(z(a)&&a.containerId&&t.has(a.containerId))return;try{Ro(a,t,n,r,o,a.x+i.offsetX,a.y+i.offsetY,i);let s=se(a,t);s&&Ro(s,t,n,r,o,s.x+i.offsetX,s.y+i.offsetY,i)}catch(s){console.error(s)}}}),e.filter(a=>it(a)).forEach(a=>{if(!a.isDeleted)try{Ro(a,t,n,r,o,a.x+i.offsetX,a.y+i.offsetY,i)}catch(s){console.error(s)}}))};var wu=(e,t)=>{if(e.width<=t)return e;let r=document.createElement("canvas").getContext("2d");r.font=Ie({fontFamily:e.fontFamily,fontSize:e.fontSize});let o=e.text;if(r.measureText(o).width>t)for(let a=o.length;a>0;a--){let s=`${o.slice(0,a)}...`;if(r.measureText(s).width<=t){o=s;break}}return Rn(e,{text:o,width:t})},Ru=(e,t)=>{let n=[];for(let r of e){if(me(r)){let o=bo({x:r.x,y:r.y-we.nameOffsetY,fontFamily:pe.Helvetica,fontSize:we.nameFontSize,lineHeight:we.nameLineHeight,strokeColor:t.exportWithDarkMode?we.nameColorDarkTheme:we.nameColorLightTheme,text:zs(r)});o.y-=o.height,o=wu(o,r.width),n.push(o)}n.push(r)}return n},q2=(e,t)=>(t=t||nr().frameRendering,{enabled:e?!0:t.enabled,outline:e?!1:t.outline,name:e?!1:t.name,clip:e?!0:t.clip}),C2=({elements:e,exportingFrame:t,frameRendering:n,exportWithDarkMode:r})=>{let o;return t?o=js(e,t):n.enabled&&n.name?o=Ru(e,{exportWithDarkMode:r}):o=e,o},ZB=async(e,t,n,{exportBackground:r,exportPadding:o=$o,viewBackgroundColor:i,exportingFrame:a},s=(U,l)=>{let f=document.createElement("canvas");return f.width=U*t.exportScale,f.height=l*t.exportScale,{canvas:f,scale:t.exportScale}},d=async()=>{await or.loadElementsFonts(e)})=>{await d();let U=q2(a??null,t.frameRendering??null);a&&(U.clip=!1);let l=C2({elements:e,exportingFrame:a,exportWithDarkMode:t.exportWithDarkMode,frameRendering:U});a&&(o=0);let[f,p,b,m]=ta(a?[a]:mi(l),o),{canvas:E,scale:g=1}=s(b,m),y=nr(),{imageCache:x}=await qd({imageCache:new Map,fileIds:Cd(l).map(h=>h.fileId),files:n});return Y2({canvas:E,rc:V2.canvas(E),elementsMap:Ze(de(l)),allElementsMap:Ze(de(dn(e))),visibleElements:l,scale:g,appState:{...t,frameRendering:U,viewBackgroundColor:r?i:null,scrollX:-f+o,scrollY:-p+o,zoom:y.zoom,shouldCacheIgnoreZoom:!1,theme:t.exportWithDarkMode?Xe.DARK:Xe.LIGHT},renderConfig:{canvasBackgroundColor:i,imageCache:x,renderGrid:!1,isExporting:!0,embedsValidationStatus:new Map,elementsPendingErasure:new Set,pendingFlowchartNodes:null}}),E},sr=e=>document.createComment(` ${e} `),kB=async(e,t,n,r)=>{let o=q2(r?.exportingFrame??null,t.frameRendering??null),{exportPadding:i=$o,exportWithDarkMode:a=!1,viewBackgroundColor:s,exportScale:d=1,exportEmbedScene:U}=t,{exportingFrame:l=null}=r||{},f=C2({elements:e,exportingFrame:l,exportWithDarkMode:a,frameRendering:o});l&&(i=0);let[p,b,m,E]=ta(l?[l]:mi(f),i),g=-p+i,y=-b+i,x=document.createElementNS(k,"svg");x.setAttribute("version","1.1"),x.setAttribute("xmlns",k),x.setAttribute("viewBox",`0 0 ${m} ${E}`),x.setAttribute("width",`${m*d}`),x.setAttribute("height",`${E*d}`),a&&x.setAttribute("filter",gr);let h=x.ownerDocument.createElementNS(k,"defs"),R=x.ownerDocument.createElementNS(k,"metadata");if(x.appendChild(sr("svg-source:excalidraw")),x.appendChild(R),x.appendChild(h),U)try{Tu({metadataElement:R,payload:Ai(e,t,n||{},"local")})}catch(O){console.error(O)}let I=Ei(e);if(I.length){let O=de(e);for(let J of I){let Pe=x.ownerDocument.createElementNS(k,"clipPath");Pe.setAttribute("id",J.id);let[Ce,ne,he,je]=A(J,O),ae=(he-Ce)/2-(J.x-Ce),_e=(je-ne)/2-(J.y-ne),mt=x.ownerDocument.createElementNS(k,"rect");mt.setAttribute("transform",`translate(${J.x+g} ${J.y+y}) rotate(${J.angle} ${ae} ${_e})`),mt.setAttribute("width",`${J.width}`),mt.setAttribute("height",`${J.height}`),l||(mt.setAttribute("rx",`${we.radius}`),mt.setAttribute("ry",`${we.radius}`)),Pe.appendChild(mt),h.appendChild(Pe)}}let v=r?.skipInliningFonts?[]:await or.generateFontFaceDeclarations(e),P=`
33
- `,S=x.ownerDocument.createElementNS(k,"style");if(S.classList.add("style-fonts"),S.appendChild(document.createTextNode(`${P}${v.join(P)}`)),h.appendChild(S),t.exportBackground&&s){let O=x.ownerDocument.createElementNS(k,"rect");O.setAttribute("x","0"),O.setAttribute("y","0"),O.setAttribute("width",`${m}`),O.setAttribute("height",`${E}`),O.setAttribute("fill",s),x.appendChild(O)}let F=V2.svg(x),_=r?.renderEmbeddables??!1;return A2(f,Ze(de(f)),F,x,n||{},{offsetX:g,offsetY:y,isExporting:!0,exportWithDarkMode:a,renderEmbeddables:_,frameRendering:o,canvasBackgroundColor:s,embedsValidationStatus:_?new Map(f.filter(O=>me(O)).map(O=>[O.id,!0])):new Map,reuseImages:r?.reuseImages??!0}),x},Tu=({payload:e,metadataElement:t})=>{let n=Eo(JSON.stringify(go({text:e})),!0);t.appendChild(sr(`payload-type:${C.excalidraw}`)),t.appendChild(sr("payload-version:2")),t.appendChild(sr("payload-start")),t.appendChild(document.createTextNode(n)),t.appendChild(sr("payload-end"))},X2=({svg:e})=>{if(e.includes(`payload-type:${C.excalidraw}`)){let t=e.match(/<!-- payload-start -->\s*(.+?)\s*<!-- payload-end -->/);if(!t)throw new Error("INVALID");let o=(e.match(/<!-- payload-version:(\d+) -->/)?.[1]||"1")!=="1";try{let i=mo(t[1],o),a=JSON.parse(i);if(!("encoded"in a)){if("type"in a&&a.type===gt.excalidraw)return i;throw new Error("FAILED")}return xo(a)}catch(i){throw console.error(i),new Error("FAILED")}}throw new Error("INVALID")},ta=(e,t)=>{let[n,r,o,i]=bt(e),a=ke(n,o)+t*2,s=ke(r,i)+t*2;return[n,r,a,s]},WB=(e,t,n)=>{let[,,r,o]=ta(e,t).map(i=>Math.trunc(i*n));return[r,o]};var Lu={selection:!0,lasso:!0,text:!0,rectangle:!0,diamond:!0,ellipse:!0,line:!0,image:!0,arrow:!0,freedraw:!0,eraser:!1,custom:!0,frame:!0,embeddable:!0,hand:!0,laser:!1,magicframe:!1},Mu=e=>Object.keys(pe).includes(e)?pe[e]:Pt,Nn=(e,t)=>{if(!t)return null;let n=t.focus||0;return q(e)?nn(t)?{...t,focus:n,fixedPoint:Zn(t.fixedPoint??[0,0])}:null:{...t,focus:n}},Gt=(e,t)=>{let n={type:t.type||e.type,version:e.version||1,versionNonce:e.versionNonce??0,index:e.index??null,isDeleted:e.isDeleted??!1,id:e.id||tn(),fillStyle:e.fillStyle||ue.fillStyle,strokeWidth:e.strokeWidth||ue.strokeWidth,strokeStyle:e.strokeStyle??ue.strokeStyle,roughness:e.roughness??ue.roughness,opacity:e.opacity==null?ue.opacity:e.opacity,angle:e.angle||0,x:t.x??e.x??0,y:t.y??e.y??0,strokeColor:e.strokeColor||ue.strokeColor,backgroundColor:e.backgroundColor||ue.backgroundColor,width:e.width||0,height:e.height||0,seed:e.seed??1,groupIds:e.groupIds??[],frameId:e.frameId??null,roundness:e.roundness?e.roundness:e.strokeSharpness==="round"?{type:_r(e.type)?He.LEGACY:He.PROPORTIONAL_RADIUS}:null,boundElements:e.boundElementIds?e.boundElementIds.map(o=>({type:"arrow",id:o})):e.boundElements??[],updated:e.updated??Kt(),link:e.link?yt(e.link):null,locked:e.locked??!1};("customData"in e||"customData"in t)&&(n.customData="customData"in t?t.customData:e.customData);let r={...e,...n,...Bd(n),...t};return delete r.strokeSharpness,delete r.boundElementIds,r},$u=e=>{switch(e={...e},e.type){case"text":delete e.rawText;let t=e.fontSize,n=e.fontFamily;if("font"in e){let[l,f]=e.font.split(" ");t=parseFloat(l),n=Mu(f)}let r=typeof e.text=="string"&&e.text||"",o=e.lineHeight||(e.height?Bs(e):yr(e.fontFamily));return e=Gt(e,{fontSize:t,fontFamily:n,text:r,textAlign:e.textAlign||ln,verticalAlign:e.verticalAlign||ur,containerId:e.containerId??null,originalText:e.originalText||r,autoResize:e.autoResize??!0,lineHeight:o}),!r&&!e.isDeleted&&(e={...e,originalText:r,isDeleted:!0},e=Qn(e)),e;case"freedraw":return Gt(e,{points:e.points,lastCommittedPoint:null,simulatePressure:e.simulatePressure,pressures:e.pressures});case"image":return Gt(e,{status:e.status||"pending",fileId:e.fileId,scale:e.scale||[1,1],crop:e.crop??null});case"line":case"draw":let{startArrowhead:i=null,endArrowhead:a=null}=e,s=e.x,d=e.y,U=!Array.isArray(e.points)||e.points.length<2?[u(0,0),u(e.width,e.height)]:e.points;return(U[0][0]!==0||U[0][1]!==0)&&({points:U,x:s,y:d}=W.getNormalizedPoints(e)),Gt(e,{type:e.type==="draw"?"line":e.type,startBinding:Nn(e,e.startBinding),endBinding:Nn(e,e.endBinding),lastCommittedPoint:null,startArrowhead:i,endArrowhead:a,points:U,x:s,y:d,...Bt(U)});case"arrow":{let{startArrowhead:l=null,endArrowhead:f="arrow"}=e,p=e.x,b=e.y,m=!Array.isArray(e.points)||e.points.length<2?[u(0,0),u(e.width,e.height)]:e.points;(m[0][0]!==0||m[0][1]!==0)&&({points:m,x:p,y:b}=W.getNormalizedPoints(e));let E={type:e.type,startBinding:Nn(e,e.startBinding),endBinding:Nn(e,e.endBinding),lastCommittedPoint:null,startArrowhead:l,endArrowhead:f,points:m,x:p,y:b,elbowed:e.elbowed,...Bt(m)};return q(e)?Gt(e,{...E,elbowed:!0,startBinding:Nn(e,e.startBinding),endBinding:Nn(e,e.endBinding),fixedSegments:e.fixedSegments,startIsSpecial:e.startIsSpecial,endIsSpecial:e.endIsSpecial}):Gt(e,E)}case"ellipse":case"rectangle":case"diamond":case"iframe":case"embeddable":return Gt(e,{});case"magicframe":case"frame":return Gt(e,{name:e.name??null})}return null},Du=(e,t)=>{if(e.boundElements){let n=e.boundElements.slice(),r=new Set;e.boundElements=n.reduce((o,i)=>{let a=t.get(i.id);if(a&&!r.has(i.id)){if(r.add(i.id),a.isDeleted)return o;o.push(i),z(a)&&!a.containerId&&(a.containerId=e.id)}return o},[])}},vu=(e,t)=>{let n=e.containerId?t.get(e.containerId):null;if(e.angle=j(n)?0:n?.angle??0,!n){e.containerId=null;return}if(!e.isDeleted&&n.boundElements&&!n.boundElements.find(r=>r.id===e.id)){let r=(n.boundElements||(n.boundElements=[])).slice();r.push({type:"text",id:e.id}),n.boundElements=r}},Nu=(e,t)=>{e.frameId&&(t.get(e.frameId)||(e.frameId=null))},k2=(e,t,n)=>{let r=new Set,o=t?de(t):null,i=dn((e||[]).reduce((s,d)=>{if(d.type!=="selection"&&!Uo(d)){let U=$u(d);if(U){let l=o?.get(d.id);l&&l.version>U.version&&(U=Qn(U,l.version)),r.has(U.id)&&(U={...U,id:tn()}),r.add(U.id),s.push(U)}}return s},[]));if(!n?.repairBindings)return i;let a=de(i);for(let s of i)s.frameId&&Nu(s,a),z(s)&&s.containerId?vu(s,a):s.boundElements&&Du(s,a),n.refreshDimensions&&z(s)&&Object.assign(s,Gd(s,Ne(s,a),a)),ge(s)&&(s.startBinding&&(!a.has(s.startBinding.elementId)||!j(s))&&(s.startBinding=null),s.endBinding&&(!a.has(s.endBinding.elementId)||!j(s))&&(s.endBinding=null));return i.map(s=>{if(q(s)&&s.startBinding==null&&s.endBinding==null&&!jr(s.points))return{...s,...Yt(s,a,{points:[u(0,0),s.points[s.points.length-1]]}),index:s.index};if(q(s)&&s.startBinding&&s.endBinding&&s.startBinding.elementId===s.endBinding.elementId&&s.points.length>1&&s.points.some(([d,U])=>Math.abs(d)>1e6||Math.abs(U)>1e6)){console.error("Fixing self-bound elbow arrow",s.id);let d=a.get(s.startBinding.elementId);return d?{...s,x:d.x+d.width/2,y:d.y-5,width:d.width,height:d.height,points:[u(0,0),u(0,-10),u(d.width/2+5,-10),u(d.width/2+5,d.height/2+5)]}:(console.error("Bound element not found",s.startBinding.elementId),s)}return s})},Fu=(e,t,n)=>{let r=t[e];return r!==void 0?r:n[e]},G2={isSidebarDocked:(e,t)=>["defaultSidebarDockedPreference",e.isSidebarDocked??Fu("defaultSidebarDockedPreference",e,t)]},Su=(e,t)=>{e=e||{};let n=nr(),r={};for(let o of Object.keys(G2))if(o in e){let[i,a]=G2[o](e,n);r[i]=a}for(let[o,i]of Object.entries(n)){let a=e[o],s=t?t[o]:void 0;r[o]=a!==void 0?a:s!==void 0?s:i}return{...r,cursorButton:t?.cursorButton||"up",penDetected:t?.penDetected??(e.penMode?e.penDetected??!1:!1),activeTool:{...Na(n,r.activeTool.type&&Lu[r.activeTool.type]?r.activeTool:{type:"selection"}),lastActiveTool:null,locked:r.activeTool.locked??!1},zoom:{value:Ki(Ir(e.zoom)?e.zoom:e.zoom?.value??n.zoom.value)},openSidebar:typeof e.openSidebar=="string"?{name:fa.name}:r.openSidebar,gridSize:Ji(Ir(e.gridSize)?e.gridSize:br),gridStep:Hi(Ir(e.gridStep)?e.gridStep:Er),editingFrame:null}},W2=(e,t,n,r)=>({elements:k2(e?.elements,n,r),appState:Su(e?.appState,t||null),files:e?.files||{}}),Z2=e=>{let t=k2(Bi(e.elements),null);return t.length?{...e,elements:t}:null},Q2=(e=[],t)=>{let n=[];for(let r of e)if(Array.isArray(r)){let o=Z2({status:t,elements:r,id:tn(),created:Date.now()});o&&n.push(o)}else{let o=r,i=Z2({...o,id:o.id||tn(),status:o.status||t,created:o.created||Date.now()});i&&n.push(i)}return n};var j2=async e=>{let t;if(e.type===C.png)try{return await(await import("./data/image-55FCGPA5.js")).decodePngMetadata(e)}catch(n){throw n.message==="INVALID"?new vt("Image doesn't contain scene","IMAGE_NOT_CONTAINS_SCENE_DATA"):new vt("Error: cannot restore image")}else if("text"in Blob?t=await e.text():t=await new Promise(n=>{let r=new FileReader;r.readAsText(e,"utf8"),r.onloadend=()=>{r.readyState===FileReader.DONE&&n(r.result)}}),e.type===C.svg)try{return X2({svg:t})}catch(n){throw n.message==="INVALID"?new vt("Image doesn't contain scene","IMAGE_NOT_CONTAINS_SCENE_DATA"):new vt("Error: cannot restore image")}return t};var _u=e=>e&&e.name.match(/\.(json|excalidraw|png|svg)$/)?.[1]||null,$O=e=>e==="png"||e==="svg",ec=e=>{let t=_u(e);return t==="png"||t==="svg"},Bu=e=>!!e&&Object.values(mr).includes(e),Lo=e=>{let{type:t}=e||{};return Bu(t)},Ou=async(e,t,n,r)=>{let o=await j2(e),i;try{try{i=JSON.parse(o)}catch(a){throw Lo(e)?new vt("Image doesn't contain scene","IMAGE_NOT_CONTAINS_SCENE_DATA"):a}if(jd(i))return{type:C.excalidraw,data:W2({elements:lo(i.elements||[]),appState:{theme:t?.theme,fileHandle:r||e.handle||null,...fo(i.appState||{}),...t?Oi(i.elements||[],t):{}},files:i.files},t,n,{repairBindings:!0,refreshDimensions:!1})};if(Vi(i))return{type:C.excalidrawlib,data:i};throw new Error("Error: invalid file")}catch(a){throw a instanceof vt?a:new Error("Error: invalid file")}},tc=async(e,t,n,r)=>{let o=await Ou(e,t,n,r);if(o.type!==C.excalidraw)throw new Error("Error: invalid file");return o.data},Ku=(e,t="unpublished")=>{let n=JSON.parse(e);if(!Vi(n))throw new Error("Invalid library");let r=n.libraryItems||n.library;return Q2(r,t)},DO=async(e,t="unpublished")=>Ku(await j2(e),t),vO=async e=>new Promise(async(t,n)=>{try{_a(e)&&(e=await e),e.toBlob(r=>{if(!r)return n(new po("Error: Canvas too big","CANVAS_POSSIBLY_TOO_BIG"));t(r)})}catch(r){n(r)}}),NO=async e=>{try{let t=await window.crypto.subtle.digest("SHA-1",await Nt(e));return Fa(new Uint8Array(t))}catch(t){return console.error(t),Pu(40)}},FO=async e=>new Promise((t,n)=>{let r=new FileReader;r.onload=()=>{let o=r.result;t(o)},r.onerror=o=>n(o),r.readAsDataURL(e)}),SO=(e,t)=>`data:${t};base64,${Eo(rr(e),!0)}`,PO=(e,t="")=>{let n=e.indexOf(","),r=atob(e.slice(n+1)),o=e.slice(0,n).split(":")[1].split(";")[0],i=new ArrayBuffer(r.length),a=new Uint8Array(i);for(let s=0;s<r.length;s++)a[s]=r.charCodeAt(s);return new File([i],t,{type:o})},_O=e=>mo(e.slice(e.indexOf(",")+1)),BO=async(e,t)=>{if(e.type===C.svg)return e;let[n,r]=await Promise.all([import("pica").then(i=>i.default),import("image-blob-reduce").then(i=>i.default)]),o=r({pica:n({features:["js","wasm"]})});if(t.outputType){let{outputType:i}=t;o._create_blob=function(a){return this.pica.toBlob(a.out_canvas,i,.8).then(s=>(a.out_blob=s,a))}}if(!Lo(e))throw new Error("Error: unsupported file type",{cause:"UNSUPPORTED"});return new File([await o.toBlob(e,{max:t.maxWidthOrHeight,alpha:!0})],e.name,{type:t.outputType||e.type})},OO=(e,t="")=>new File([new TextEncoder().encode(e)],t,{type:C.svg}),KO=async(e,t="")=>{let n;try{n=await fetch(e)}catch{throw new Error("Error: failed to fetch image",{cause:"FETCH_ERROR"})}if(!n.ok)throw new Error("Error: failed to fetch image",{cause:"FETCH_ERROR"});let r=await n.blob();if(r.type&&Lo(r)){let o=t||r.name||"";return new File([r],o,{type:r.type})}throw new Error("Error: unsupported file type",{cause:"UNSUPPORTED"})},JO=async e=>{let t=Array.from(e.dataTransfer.files),n=await Ju(e);return{files:t?await Promise.all(t.map(o=>qi(o))):null,fileHandle:n}},Ju=async e=>{if(Qd)try{return await e.dataTransfer.items[0].getAsFileSystemHandle()||null}catch(t){return console.warn(t.name,t.message),null}return null},z2=e=>{let t=null,n=`${[...new Uint8Array(e).slice(0,8)].join(" ")} `,r={png:"137 80 78 71 13 10 26 10 ",jpg:"255 216 255 ",gif:"71 73 70 56 57 97 "};return n===r.png?t=C.png:n.startsWith(r.jpg)?t=C.jpg:n.startsWith(r.gif)&&(t=C.gif),t},To=(e,t,n)=>new File([e],n||"",{type:t}),qi=async e=>{if(e.type){if(Lo(e)){let t=await Nt(e),n=z2(t);n&&n!==e.type&&(e=To(t,n,e.name))}}else if(e?.name?.endsWith(".excalidrawlib"))e=To(await Nt(e),C.excalidrawlib,e.name);else if(e?.name?.endsWith(".excalidraw"))e=To(await Nt(e),C.excalidraw,e.name);else{let t=await Nt(e),n=z2(t);n&&(e=To(t,n,e.name))}return e},Nt=e=>"arrayBuffer"in e?e.arrayBuffer():new Promise((t,n)=>{let r=new FileReader;r.onload=o=>{if(!o.target?.result)return n(new Error("Couldn't convert blob to ArrayBuffer"));t(o.target.result)},r.readAsArrayBuffer(e)});var Yu=async e=>{let n=t6(new Uint8Array(await Nt(e))).find(r=>r.name==="tEXt");return n?e6.decode(n.data):null},ZO=async({blob:e,metadata:t})=>{let n=t6(new Uint8Array(await Nt(e))),r=e6.encode(C.excalidraw,JSON.stringify(go({text:t,compress:!0})));return n.splice(-1,0,r),new Blob([Hu(n)],{type:C.png})},kO=async e=>{let t=await Yu(e);if(t?.keyword===C.excalidraw)try{let n=JSON.parse(t.text);if(!("encoded"in n)){if("type"in n&&n.type===gt.excalidraw)return t.text;throw new Error("FAILED")}return xo(n)}catch(n){throw console.error(n),new Error("FAILED")}throw new Error("INVALID")};export{Xu as a,Gu as b,Zu as c,ku as d,cr as e,Ur as f,V as g,Wu as h,Qu as i,zu as j,ju as k,e9 as l,t9 as m,n9 as n,lr as o,a9 as p,s9 as q,d9 as r,c9 as s,U9 as t,l9 as u,f9 as v,p9 as w,u9 as x,ra as y,oa as z,b9 as A,E9 as B,m9 as C,Fn as D,g9 as E,x9 as F,h9 as G,y9 as H,I9 as I,w9 as J,pe as K,Xe as L,we as M,R9 as N,St as O,Pt as P,ln as Q,ur as R,i6 as S,a6 as T,T9 as U,L9 as V,M9 as W,$9 as X,br as Y,mr as Z,C as _,D9 as $,v9 as aa,gt as ba,Mo as ca,N9 as da,F9 as ea,S9 as fa,P9 as ga,_9 as ha,ia,aa as ja,B9 as ka,gr as la,O9 as ma,K9 as na,J9 as oa,H9 as pa,Y9 as qa,A9 as ra,V9 as sa,sa as ta,$o as ua,q9 as va,C9 as wa,k as xa,X9 as ya,Do as za,ye as Aa,Wt as Ba,vo as Ca,He as Da,G9 as Ea,d6 as Fa,Z9 as Ga,fa as Ha,k9 as Ia,W9 as Ja,Q9 as Ka,pa as La,Fo as Ma,z9 as Na,ua as Oa,ba as Pa,j9 as Qa,c6 as Ra,yr as Sa,Ea as Ta,ga as Ua,le as Va,U3 as Wa,l3 as Xa,f3 as Ya,p3 as Za,So as _a,te as $a,xa as ab,E3 as bb,Ir as cb,h3 as db,_n as eb,y3 as fb,Me as gb,M as hb,f6 as ib,wr as jb,G as kb,Le as lb,u as mb,L as nb,un as ob,Q as pb,B as qb,jt as rb,_t as sb,bn as tb,Q3 as ub,Yn as vb,tb as wb,nb as xb,Bt as yb,Jo as zb,Ho as Ab,Sb as Bb,Pb as Cb,_b as Db,y6 as Eb,Bb as Fb,Ob as Gb,Yo as Hb,Ie as Ib,$r as Jb,Da as Kb,va as Lb,Kb as Mb,Jb as Nb,ke as Ob,Na as Pb,Hb as Qb,en as Rb,Ao as Sb,Yb as Tb,Ot as Ub,Ab as Vb,Vb as Wb,qb as Xb,ht as Yb,ma as Zb,Cb as _b,Xb as $b,Gb as ac,Kt as bc,de as cc,Zb as dc,kb as ec,Wb as fc,$e as gc,rt as hc,Qb as ic,zb as jc,jb as kc,_a as lc,eE as mc,Vo as nc,tE as oc,Nr as pc,be as qc,nE as rc,rE as sc,oE as tc,iE as uc,aE as vc,sE as wc,Ba as xc,Ze as yc,ft as zc,dE as Ac,Jt as Bc,tn as Cc,yt as Dc,gE as Ec,Ja as Fc,Ht as Gc,mn as Hc,Sr as Ic,Pr as Jc,it as Kc,z as Lc,Xa as Mc,Ga as Nc,me as Oc,Ae as Pc,ge as Qc,j as Rc,q as Sc,Co as Tc,Xo as Uc,P6 as Vc,It as Wc,_6 as Xc,ka as Yc,VE as Zc,gn as _c,at as $c,_r as ad,qE as bd,CE as cd,jE as dd,em as ed,tm as fd,nm as gd,rm as hd,om as id,im as jd,am as kd,sm as ld,za as md,cm as nd,ja as od,es as pd,ts as qd,ns as rd,rs as sd,Um as td,os as ud,is as vd,as as wd,ss as xd,lm as yd,fm as zd,pm as Ad,um as Bd,bm as Cd,Em as Dd,mm as Ed,gm as Fd,xm as Gd,hm as Hd,ym as Id,Im as Jd,Rm as Kd,Tm as Ld,Lm as Md,Mm as Nd,$m as Od,Dm as Pd,vm as Qd,Nm as Rd,Sm as Sd,Pm as Td,_m as Ud,Bm as Vd,Jm as Wd,Ym as Xd,Am as Yd,Vm as Zd,qm as _d,Wm as $d,Qm as ae,zm as be,jm as ce,e4 as de,t4 as ee,n4 as fe,r4 as ge,o4 as he,i4 as ie,a4 as je,s4 as ke,d4 as le,l4 as me,b4 as ne,E4 as oe,m4 as pe,g4 as qe,x4 as re,h4 as se,y4 as te,I4 as ue,w4 as ve,T4 as we,L4 as xe,M4 as ye,$4 as ze,D4 as Ae,v4 as Be,N4 as Ce,F4 as De,S4 as Ee,P4 as Fe,_4 as Ge,B4 as He,O4 as Ie,K4 as Je,J4 as Ke,H4 as Le,Y4 as Me,A4 as Ne,V4 as Oe,q4 as Pe,C4 as Qe,X4 as Re,G4 as Se,Z4 as Te,k4 as Ue,W4 as Ve,Q4 as We,z4 as Xe,j4 as Ye,eg as Ze,tg as _e,ng as $e,rg as af,og as bf,ig as cf,sg as df,dg as ef,cg as ff,Ug as gf,lg as hf,ug as if,bg as jf,Eg as kf,mg as lf,gg as mf,xg as nf,hg as of,yg as pf,Ig as qf,Tg as rf,Lg as sf,Mg as tf,$g as uf,Dg as vf,vg as wf,Ng as xf,Fg as yf,Sg as zf,Pg as Af,_g as Bf,Bg as Cf,Og as Df,Kg as Ef,Jg as Ff,Hg as Gf,Yg as Hf,Ag as If,Vg as Jf,qg as Kf,Cg as Lf,Zg as Mf,kg as Nf,Wg as Of,Qg as Pf,zg as Qf,jg as Rf,ex as Sf,tx as Tf,nx as Uf,rx as Vf,ox as Wf,ix as Xf,Jr as Yf,Y6 as Zf,Go as _f,Sx as $f,A6 as ag,Te as bg,Oe as cg,We as dg,dt as eg,ve as fg,Zo as gg,Cn as hg,bs as ig,Es as jg,Bx as kg,Tt as lg,Kh as mg,Jh as ng,Hh as og,ii as pg,Tn as qg,Yh as rg,Ah as sg,Os as tg,sn as ug,ry as vg,Zr as wg,Js as xg,Hs as yg,se as zg,Ne as Ag,oy as Bg,iy as Cg,ay as Dg,sy as Eg,dy as Fg,Ui as Gg,Ct as Hg,zn as Ig,cy as Jg,ch as Kg,Wo as Lg,xs as Mg,hs as Ng,Qo as Og,Uh as Pg,lh as Qg,fh as Rg,qr as Sg,tf as Tg,rn as Ug,ph as Vg,kr as Wg,Ls as Xg,uh as Yg,bh as Zg,Wr as _g,Eh as $g,Ar as ah,Vr as bh,mh as ch,Yt as dh,ee as eh,Rn as fh,Qn as gh,Uo as hh,td as ih,hR as jh,yR as kh,Ud as lh,Bd as mh,LR as nh,MR as oh,Od as ph,Bi as qh,cd as rh,Xs as sh,Vf as th,Zs as uh,Ny as vh,no as wh,Xt as xh,Fy as yh,Sy as zh,jn as Ah,Ei as Bh,mi as Ch,Py as Dh,_y as Eh,ze as Fh,By as Gh,Cf as Hh,Ws as Ih,Xf as Jh,Oy as Kh,Ky as Lh,Qs as Mh,zs as Nh,js as Oh,Jy as Ph,nd as Qh,io as Rh,ky as Sh,Gf as Th,Zf as Uh,Mt as Vh,kf as Wh,xi as Xh,Wy as Yh,Qf as Zh,rd as _h,tI as $h,zf as ai,nI as bi,ed as ci,rI as di,jf as ei,$t as fi,oI as gi,iI as hi,aI as ii,sI as ji,dI as ki,od as li,cI as mi,UI as ni,Ii as oi,gI as pi,wi as qi,dn as ri,Wn as si,W as ti,ow as ui,wn as vi,us as wi,Ut as xi,Ve as yi,ut as zi,d8 as Ai,sw as Bi,c8 as Ci,U8 as Di,$i as Ei,dw as Fi,l8 as Gi,Fe as Hi,uw as Ii,Ln as Ji,bw as Ki,b8 as Li,Nw as Mi,Un as Ni,Ni as Oi,fe as Pi,A as Qi,pi as Ri,Be as Si,bt as Ti,UR as Ui,tr as Vi,lR as Wi,fR as Xi,JE as Yi,Or as Zi,lT as _i,fT as $i,pT as aj,uT as bj,bT as cj,bo as dj,Gd as ej,ET as fj,mT as gj,gT as hj,xT as ij,ki as jj,P2 as kj,V_ as lj,q_ as mj,K8 as nj,qd as oj,Cd as pj,nT as qj,P_ as rj,__ as sj,lu as tj,$2 as uj,B_ as vj,O8 as wj,Oi as xj,Ki as yj,Hi as zj,nr as Aj,NR as Bj,FR as Cj,uo as Dj,vt as Ej,Vd as Fj,or as Gj,Qd as Hj,zd as Ij,Yi as Jj,Ai as Kj,qT as Lj,CT as Mj,G8 as Nj,XT as Oj,ea as Pj,hu as Qj,z_ as Rj,nB as Sj,_2 as Tj,B2 as Uj,Iu as Vj,Y2 as Wj,ZB as Xj,kB as Yj,WB as Zj,k2 as _j,Su as $j,W2 as ak,Q2 as bk,Yu as ck,ZO as dk,kO as ek,_u as fk,$O as gk,ec as hk,Bu as ik,Lo as jk,Ou as kk,tc as lk,Ku as mk,DO as nk,vO as ok,NO as pk,FO as qk,SO as rk,PO as sk,_O as tk,BO as uk,OO as vk,KO as wk,JO as xk,To as yk,qi as zk};
33
+ `,S=x.ownerDocument.createElementNS(k,"style");if(S.classList.add("style-fonts"),S.appendChild(document.createTextNode(`${P}${v.join(P)}`)),h.appendChild(S),t.exportBackground&&s){let O=x.ownerDocument.createElementNS(k,"rect");O.setAttribute("x","0"),O.setAttribute("y","0"),O.setAttribute("width",`${m}`),O.setAttribute("height",`${E}`),O.setAttribute("fill",s),x.appendChild(O)}let F=V2.svg(x),_=r?.renderEmbeddables??!1;return A2(f,Ze(de(f)),F,x,n||{},{offsetX:g,offsetY:y,isExporting:!0,exportWithDarkMode:a,renderEmbeddables:_,frameRendering:o,canvasBackgroundColor:s,embedsValidationStatus:_?new Map(f.filter(O=>me(O)).map(O=>[O.id,!0])):new Map,reuseImages:r?.reuseImages??!0}),x},Tu=({payload:e,metadataElement:t})=>{let n=Eo(JSON.stringify(go({text:e})),!0);t.appendChild(sr(`payload-type:${C.excalidraw}`)),t.appendChild(sr("payload-version:2")),t.appendChild(sr("payload-start")),t.appendChild(document.createTextNode(n)),t.appendChild(sr("payload-end"))},X2=({svg:e})=>{if(e.includes(`payload-type:${C.excalidraw}`)){let t=e.match(/<!-- payload-start -->\s*(.+?)\s*<!-- payload-end -->/);if(!t)throw new Error("INVALID");let o=(e.match(/<!-- payload-version:(\d+) -->/)?.[1]||"1")!=="1";try{let i=mo(t[1],o),a=JSON.parse(i);if(!("encoded"in a)){if("type"in a&&a.type===gt.excalidraw)return i;throw new Error("FAILED")}return xo(a)}catch(i){throw console.error(i),new Error("FAILED")}}throw new Error("INVALID")},ta=(e,t)=>{let[n,r,o,i]=bt(e),a=ke(n,o)+t*2,s=ke(r,i)+t*2;return[n,r,a,s]},WB=(e,t,n)=>{let[,,r,o]=ta(e,t).map(i=>Math.trunc(i*n));return[r,o]};var Lu={selection:!0,lasso:!0,text:!0,rectangle:!0,diamond:!0,ellipse:!0,line:!0,image:!0,arrow:!0,freedraw:!0,eraser:!1,custom:!0,frame:!0,embeddable:!0,hand:!0,laser:!1,magicframe:!1},Mu=e=>Object.keys(pe).includes(e)?pe[e]:Pt,Nn=(e,t)=>{if(!t)return null;let n=t.focus||0;return q(e)?nn(t)?{...t,focus:n,fixedPoint:Zn(t.fixedPoint??[0,0])}:null:{...t,focus:n}},Gt=(e,t)=>{let n={type:t.type||e.type,version:e.version||1,versionNonce:e.versionNonce??0,index:e.index??null,isDeleted:e.isDeleted??!1,id:e.id||tn(),fillStyle:e.fillStyle||ue.fillStyle,strokeWidth:e.strokeWidth||ue.strokeWidth,strokeStyle:e.strokeStyle??ue.strokeStyle,roughness:e.roughness??ue.roughness,opacity:e.opacity==null?ue.opacity:e.opacity,angle:e.angle||0,x:t.x??e.x??0,y:t.y??e.y??0,strokeColor:e.strokeColor||ue.strokeColor,backgroundColor:e.backgroundColor||ue.backgroundColor,width:e.width||0,height:e.height||0,seed:e.seed??1,groupIds:e.groupIds??[],frameId:e.frameId??null,roundness:e.roundness?e.roundness:e.strokeSharpness==="round"?{type:_r(e.type)?He.LEGACY:He.PROPORTIONAL_RADIUS}:null,boundElements:e.boundElementIds?e.boundElementIds.map(o=>({type:"arrow",id:o})):e.boundElements??[],updated:e.updated??Kt(),link:e.link?yt(e.link):null,locked:e.locked??!1};("customData"in e||"customData"in t)&&(n.customData="customData"in t?t.customData:e.customData);let r={...e,...n,...Bd(n),...t};return delete r.strokeSharpness,delete r.boundElementIds,r},$u=e=>{switch(e={...e},e.type){case"text":delete e.rawText;let t=e.fontSize,n=e.fontFamily;if("font"in e){let[l,f]=e.font.split(" ");t=parseFloat(l),n=Mu(f)}let r=typeof e.text=="string"&&e.text||"",o=e.lineHeight||(e.height?Bs(e):yr(e.fontFamily));return e=Gt(e,{fontSize:t,fontFamily:n,text:r,textAlign:e.textAlign||ln,verticalAlign:e.verticalAlign||ur,containerId:e.containerId??null,originalText:e.originalText||r,autoResize:e.autoResize??!0,lineHeight:o}),!r&&!e.isDeleted&&(e={...e,originalText:r,isDeleted:!0},e=Qn(e)),e;case"freedraw":return Gt(e,{points:e.points,lastCommittedPoint:null,simulatePressure:e.simulatePressure,pressures:e.pressures});case"image":return Gt(e,{status:e.status||"pending",fileId:e.fileId,scale:e.scale||[1,1],crop:e.crop??null});case"line":case"draw":let{startArrowhead:i=null,endArrowhead:a=null}=e,s=e.x,d=e.y,U=!Array.isArray(e.points)||e.points.length<2?[u(0,0),u(e.width,e.height)]:e.points;return(U[0][0]!==0||U[0][1]!==0)&&({points:U,x:s,y:d}=W.getNormalizedPoints(e)),Gt(e,{type:e.type==="draw"?"line":e.type,startBinding:Nn(e,e.startBinding),endBinding:Nn(e,e.endBinding),lastCommittedPoint:null,startArrowhead:i,endArrowhead:a,points:U,x:s,y:d,...Bt(U)});case"arrow":{let{startArrowhead:l=null,endArrowhead:f="arrow"}=e,p=e.x,b=e.y,m=!Array.isArray(e.points)||e.points.length<2?[u(0,0),u(e.width,e.height)]:e.points;(m[0][0]!==0||m[0][1]!==0)&&({points:m,x:p,y:b}=W.getNormalizedPoints(e));let E={type:e.type,startBinding:Nn(e,e.startBinding),endBinding:Nn(e,e.endBinding),lastCommittedPoint:null,startArrowhead:l,endArrowhead:f,points:m,x:p,y:b,elbowed:e.elbowed,...Bt(m)};return q(e)?Gt(e,{...E,elbowed:!0,startBinding:Nn(e,e.startBinding),endBinding:Nn(e,e.endBinding),fixedSegments:e.fixedSegments,startIsSpecial:e.startIsSpecial,endIsSpecial:e.endIsSpecial}):Gt(e,E)}case"ellipse":case"rectangle":case"diamond":case"iframe":case"embeddable":return Gt(e,{});case"magicframe":case"frame":return Gt(e,{name:e.name??null})}return null},Du=(e,t)=>{if(e.boundElements){let n=e.boundElements.slice(),r=new Set;e.boundElements=n.reduce((o,i)=>{let a=t.get(i.id);if(a&&!r.has(i.id)){if(r.add(i.id),a.isDeleted)return o;o.push(i),z(a)&&!a.containerId&&(a.containerId=e.id)}return o},[])}},vu=(e,t)=>{let n=e.containerId?t.get(e.containerId):null;if(e.angle=j(n)?0:n?.angle??0,!n){e.containerId=null;return}if(!e.isDeleted&&n.boundElements&&!n.boundElements.find(r=>r.id===e.id)){let r=(n.boundElements||(n.boundElements=[])).slice();r.push({type:"text",id:e.id}),n.boundElements=r}},Nu=(e,t)=>{e.frameId&&(t.get(e.frameId)||(e.frameId=null))},k2=(e,t,n)=>{let r=new Set,o=t?de(t):null,i=dn((e||[]).reduce((s,d)=>{if(d.type!=="selection"&&!Uo(d)){let U=$u(d);if(U){let l=o?.get(d.id);l&&l.version>U.version&&(U=Qn(U,l.version)),r.has(U.id)&&(U={...U,id:tn()}),r.add(U.id),s.push(U)}}return s},[]));if(!n?.repairBindings)return i;let a=de(i);for(let s of i)s.frameId&&Nu(s,a),z(s)&&s.containerId?vu(s,a):s.boundElements&&Du(s,a),n.refreshDimensions&&z(s)&&Object.assign(s,Gd(s,Ne(s,a),a)),ge(s)&&(s.startBinding&&(!a.has(s.startBinding.elementId)||!j(s))&&(s.startBinding=null),s.endBinding&&(!a.has(s.endBinding.elementId)||!j(s))&&(s.endBinding=null));return i.map(s=>{if(q(s)&&s.startBinding==null&&s.endBinding==null&&!jr(s.points))return{...s,...Yt(s,a,{points:[u(0,0),s.points[s.points.length-1]]}),index:s.index};if(q(s)&&s.startBinding&&s.endBinding&&s.startBinding.elementId===s.endBinding.elementId&&s.points.length>1&&s.points.some(([d,U])=>Math.abs(d)>1e6||Math.abs(U)>1e6)){console.error("Fixing self-bound elbow arrow",s.id);let d=a.get(s.startBinding.elementId);return d?{...s,x:d.x+d.width/2,y:d.y-5,width:d.width,height:d.height,points:[u(0,0),u(0,-10),u(d.width/2+5,-10),u(d.width/2+5,d.height/2+5)]}:(console.error("Bound element not found",s.startBinding.elementId),s)}return s})},Fu=(e,t,n)=>{let r=t[e];return r!==void 0?r:n[e]},G2={isSidebarDocked:(e,t)=>["defaultSidebarDockedPreference",e.isSidebarDocked??Fu("defaultSidebarDockedPreference",e,t)]},Su=(e,t)=>{e=e||{};let n=nr(),r={};for(let o of Object.keys(G2))if(o in e){let[i,a]=G2[o](e,n);r[i]=a}for(let[o,i]of Object.entries(n)){let a=e[o],s=t?t[o]:void 0;r[o]=a!==void 0?a:s!==void 0?s:i}return{...r,cursorButton:t?.cursorButton||"up",penDetected:t?.penDetected??(e.penMode?e.penDetected??!1:!1),activeTool:{...Na(n,r.activeTool.type&&Lu[r.activeTool.type]?r.activeTool:{type:"selection"}),lastActiveTool:null,locked:r.activeTool.locked??!1},zoom:{value:Ki(Ir(e.zoom)?e.zoom:e.zoom?.value??n.zoom.value)},openSidebar:typeof e.openSidebar=="string"?{name:fa.name}:r.openSidebar,gridSize:Ji(Ir(e.gridSize)?e.gridSize:br),gridStep:Hi(Ir(e.gridStep)?e.gridStep:Er),editingFrame:null}},W2=(e,t,n,r)=>({elements:k2(e?.elements,n,r),appState:Su(e?.appState,t||null),files:e?.files||{}}),Z2=e=>{let t=k2(Bi(e.elements),null);return t.length?{...e,elements:t}:null},Q2=(e=[],t)=>{let n=[];for(let r of e)if(Array.isArray(r)){let o=Z2({status:t,elements:r,id:tn(),created:Date.now()});o&&n.push(o)}else{let o=r,i=Z2({...o,id:o.id||tn(),status:o.status||t,created:o.created||Date.now()});i&&n.push(i)}return n};var j2=async e=>{let t;if(e.type===C.png)try{return await(await import("./data/image-EKW6RBW7.js")).decodePngMetadata(e)}catch(n){throw n.message==="INVALID"?new vt("Image doesn't contain scene","IMAGE_NOT_CONTAINS_SCENE_DATA"):new vt("Error: cannot restore image")}else if("text"in Blob?t=await e.text():t=await new Promise(n=>{let r=new FileReader;r.readAsText(e,"utf8"),r.onloadend=()=>{r.readyState===FileReader.DONE&&n(r.result)}}),e.type===C.svg)try{return X2({svg:t})}catch(n){throw n.message==="INVALID"?new vt("Image doesn't contain scene","IMAGE_NOT_CONTAINS_SCENE_DATA"):new vt("Error: cannot restore image")}return t};var _u=e=>e&&e.name.match(/\.(json|excalidraw|png|svg)$/)?.[1]||null,$O=e=>e==="png"||e==="svg",ec=e=>{let t=_u(e);return t==="png"||t==="svg"},Bu=e=>!!e&&Object.values(mr).includes(e),Lo=e=>{let{type:t}=e||{};return Bu(t)},Ou=async(e,t,n,r)=>{let o=await j2(e),i;try{try{i=JSON.parse(o)}catch(a){throw Lo(e)?new vt("Image doesn't contain scene","IMAGE_NOT_CONTAINS_SCENE_DATA"):a}if(jd(i))return{type:C.excalidraw,data:W2({elements:lo(i.elements||[]),appState:{theme:t?.theme,fileHandle:r||e.handle||null,...fo(i.appState||{}),...t?Oi(i.elements||[],t):{}},files:i.files},t,n,{repairBindings:!0,refreshDimensions:!1})};if(Vi(i))return{type:C.excalidrawlib,data:i};throw new Error("Error: invalid file")}catch(a){throw a instanceof vt?a:new Error("Error: invalid file")}},tc=async(e,t,n,r)=>{let o=await Ou(e,t,n,r);if(o.type!==C.excalidraw)throw new Error("Error: invalid file");return o.data},Ku=(e,t="unpublished")=>{let n=JSON.parse(e);if(!Vi(n))throw new Error("Invalid library");let r=n.libraryItems||n.library;return Q2(r,t)},DO=async(e,t="unpublished")=>Ku(await j2(e),t),vO=async e=>new Promise(async(t,n)=>{try{_a(e)&&(e=await e),e.toBlob(r=>{if(!r)return n(new po("Error: Canvas too big","CANVAS_POSSIBLY_TOO_BIG"));t(r)})}catch(r){n(r)}}),NO=async e=>{try{let t=await window.crypto.subtle.digest("SHA-1",await Nt(e));return Fa(new Uint8Array(t))}catch(t){return console.error(t),Pu(40)}},FO=async e=>new Promise((t,n)=>{let r=new FileReader;r.onload=()=>{let o=r.result;t(o)},r.onerror=o=>n(o),r.readAsDataURL(e)}),SO=(e,t)=>`data:${t};base64,${Eo(rr(e),!0)}`,PO=(e,t="")=>{let n=e.indexOf(","),r=atob(e.slice(n+1)),o=e.slice(0,n).split(":")[1].split(";")[0],i=new ArrayBuffer(r.length),a=new Uint8Array(i);for(let s=0;s<r.length;s++)a[s]=r.charCodeAt(s);return new File([i],t,{type:o})},_O=e=>mo(e.slice(e.indexOf(",")+1)),BO=async(e,t)=>{if(e.type===C.svg)return e;let[n,r]=await Promise.all([import("pica").then(i=>i.default),import("image-blob-reduce").then(i=>i.default)]),o=r({pica:n({features:["js","wasm"]})});if(t.outputType){let{outputType:i}=t;o._create_blob=function(a){return this.pica.toBlob(a.out_canvas,i,.8).then(s=>(a.out_blob=s,a))}}if(!Lo(e))throw new Error("Error: unsupported file type",{cause:"UNSUPPORTED"});return new File([await o.toBlob(e,{max:t.maxWidthOrHeight,alpha:!0})],e.name,{type:t.outputType||e.type})},OO=(e,t="")=>new File([new TextEncoder().encode(e)],t,{type:C.svg}),KO=async(e,t="")=>{let n;try{n=await fetch(e)}catch{throw new Error("Error: failed to fetch image",{cause:"FETCH_ERROR"})}if(!n.ok)throw new Error("Error: failed to fetch image",{cause:"FETCH_ERROR"});let r=await n.blob();if(r.type&&Lo(r)){let o=t||r.name||"";return new File([r],o,{type:r.type})}throw new Error("Error: unsupported file type",{cause:"UNSUPPORTED"})},JO=async e=>{let t=Array.from(e.dataTransfer.files),n=await Ju(e);return{files:t?await Promise.all(t.map(o=>qi(o))):null,fileHandle:n}},Ju=async e=>{if(Qd)try{return await e.dataTransfer.items[0].getAsFileSystemHandle()||null}catch(t){return console.warn(t.name,t.message),null}return null},z2=e=>{let t=null,n=`${[...new Uint8Array(e).slice(0,8)].join(" ")} `,r={png:"137 80 78 71 13 10 26 10 ",jpg:"255 216 255 ",gif:"71 73 70 56 57 97 "};return n===r.png?t=C.png:n.startsWith(r.jpg)?t=C.jpg:n.startsWith(r.gif)&&(t=C.gif),t},To=(e,t,n)=>new File([e],n||"",{type:t}),qi=async e=>{if(e.type){if(Lo(e)){let t=await Nt(e),n=z2(t);n&&n!==e.type&&(e=To(t,n,e.name))}}else if(e?.name?.endsWith(".excalidrawlib"))e=To(await Nt(e),C.excalidrawlib,e.name);else if(e?.name?.endsWith(".excalidraw"))e=To(await Nt(e),C.excalidraw,e.name);else{let t=await Nt(e),n=z2(t);n&&(e=To(t,n,e.name))}return e},Nt=e=>"arrayBuffer"in e?e.arrayBuffer():new Promise((t,n)=>{let r=new FileReader;r.onload=o=>{if(!o.target?.result)return n(new Error("Couldn't convert blob to ArrayBuffer"));t(o.target.result)},r.readAsArrayBuffer(e)});var Yu=async e=>{let n=t6(new Uint8Array(await Nt(e))).find(r=>r.name==="tEXt");return n?e6.decode(n.data):null},ZO=async({blob:e,metadata:t})=>{let n=t6(new Uint8Array(await Nt(e))),r=e6.encode(C.excalidraw,JSON.stringify(go({text:t,compress:!0})));return n.splice(-1,0,r),new Blob([Hu(n)],{type:C.png})},kO=async e=>{let t=await Yu(e);if(t?.keyword===C.excalidraw)try{let n=JSON.parse(t.text);if(!("encoded"in n)){if("type"in n&&n.type===gt.excalidraw)return t.text;throw new Error("FAILED")}return xo(n)}catch(n){throw console.error(n),new Error("FAILED")}throw new Error("INVALID")};export{Xu as a,Gu as b,Zu as c,ku as d,cr as e,Ur as f,V as g,Wu as h,Qu as i,zu as j,ju as k,e9 as l,t9 as m,n9 as n,lr as o,a9 as p,s9 as q,d9 as r,c9 as s,U9 as t,l9 as u,f9 as v,p9 as w,u9 as x,ra as y,oa as z,b9 as A,E9 as B,m9 as C,Fn as D,g9 as E,x9 as F,h9 as G,y9 as H,I9 as I,w9 as J,pe as K,Xe as L,we as M,R9 as N,St as O,Pt as P,ln as Q,ur as R,i6 as S,a6 as T,T9 as U,L9 as V,M9 as W,$9 as X,br as Y,mr as Z,C as _,D9 as $,v9 as aa,gt as ba,Mo as ca,N9 as da,F9 as ea,S9 as fa,P9 as ga,_9 as ha,ia,aa as ja,B9 as ka,gr as la,O9 as ma,K9 as na,J9 as oa,H9 as pa,Y9 as qa,A9 as ra,V9 as sa,sa as ta,$o as ua,q9 as va,C9 as wa,k as xa,X9 as ya,Do as za,ye as Aa,Wt as Ba,vo as Ca,He as Da,G9 as Ea,d6 as Fa,Z9 as Ga,fa as Ha,k9 as Ia,W9 as Ja,Q9 as Ka,pa as La,Fo as Ma,z9 as Na,ua as Oa,ba as Pa,j9 as Qa,c6 as Ra,yr as Sa,Ea as Ta,ga as Ua,le as Va,U3 as Wa,l3 as Xa,f3 as Ya,p3 as Za,So as _a,te as $a,xa as ab,E3 as bb,Ir as cb,h3 as db,_n as eb,y3 as fb,Me as gb,M as hb,f6 as ib,wr as jb,G as kb,Le as lb,u as mb,L as nb,un as ob,Q as pb,B as qb,jt as rb,_t as sb,bn as tb,Q3 as ub,Yn as vb,tb as wb,nb as xb,Bt as yb,Jo as zb,Ho as Ab,Sb as Bb,Pb as Cb,_b as Db,y6 as Eb,Bb as Fb,Ob as Gb,Yo as Hb,Ie as Ib,$r as Jb,Da as Kb,va as Lb,Kb as Mb,Jb as Nb,ke as Ob,Na as Pb,Hb as Qb,en as Rb,Ao as Sb,Yb as Tb,Ot as Ub,Ab as Vb,Vb as Wb,qb as Xb,ht as Yb,ma as Zb,Cb as _b,Xb as $b,Gb as ac,Kt as bc,de as cc,Zb as dc,kb as ec,Wb as fc,$e as gc,rt as hc,Qb as ic,zb as jc,jb as kc,_a as lc,eE as mc,Vo as nc,tE as oc,Nr as pc,be as qc,nE as rc,rE as sc,oE as tc,iE as uc,aE as vc,sE as wc,Ba as xc,Ze as yc,ft as zc,dE as Ac,Jt as Bc,tn as Cc,yt as Dc,gE as Ec,Ja as Fc,Ht as Gc,mn as Hc,Sr as Ic,Pr as Jc,it as Kc,z as Lc,Xa as Mc,Ga as Nc,me as Oc,Ae as Pc,ge as Qc,j as Rc,q as Sc,Co as Tc,Xo as Uc,P6 as Vc,It as Wc,_6 as Xc,ka as Yc,VE as Zc,gn as _c,at as $c,_r as ad,qE as bd,CE as cd,jE as dd,em as ed,tm as fd,nm as gd,rm as hd,om as id,im as jd,am as kd,sm as ld,za as md,cm as nd,ja as od,es as pd,ts as qd,ns as rd,rs as sd,Um as td,os as ud,is as vd,as as wd,ss as xd,lm as yd,fm as zd,pm as Ad,um as Bd,bm as Cd,Em as Dd,mm as Ed,gm as Fd,xm as Gd,hm as Hd,ym as Id,Im as Jd,Rm as Kd,Tm as Ld,Lm as Md,Mm as Nd,$m as Od,Dm as Pd,vm as Qd,Nm as Rd,Sm as Sd,Pm as Td,_m as Ud,Bm as Vd,Jm as Wd,Ym as Xd,Am as Yd,Vm as Zd,qm as _d,Wm as $d,Qm as ae,zm as be,jm as ce,e4 as de,t4 as ee,n4 as fe,r4 as ge,o4 as he,i4 as ie,a4 as je,s4 as ke,d4 as le,l4 as me,b4 as ne,E4 as oe,m4 as pe,g4 as qe,x4 as re,h4 as se,y4 as te,I4 as ue,w4 as ve,T4 as we,L4 as xe,M4 as ye,$4 as ze,D4 as Ae,v4 as Be,N4 as Ce,F4 as De,S4 as Ee,P4 as Fe,_4 as Ge,B4 as He,O4 as Ie,K4 as Je,J4 as Ke,H4 as Le,Y4 as Me,A4 as Ne,V4 as Oe,q4 as Pe,C4 as Qe,X4 as Re,G4 as Se,Z4 as Te,k4 as Ue,W4 as Ve,Q4 as We,z4 as Xe,j4 as Ye,eg as Ze,tg as _e,ng as $e,rg as af,og as bf,ig as cf,sg as df,dg as ef,cg as ff,Ug as gf,lg as hf,ug as if,bg as jf,Eg as kf,mg as lf,gg as mf,xg as nf,hg as of,yg as pf,Ig as qf,Tg as rf,Lg as sf,Mg as tf,$g as uf,Dg as vf,vg as wf,Ng as xf,Fg as yf,Sg as zf,Pg as Af,_g as Bf,Bg as Cf,Og as Df,Kg as Ef,Jg as Ff,Hg as Gf,Yg as Hf,Ag as If,Vg as Jf,qg as Kf,Cg as Lf,Zg as Mf,kg as Nf,Wg as Of,Qg as Pf,zg as Qf,jg as Rf,ex as Sf,tx as Tf,nx as Uf,rx as Vf,ox as Wf,ix as Xf,Jr as Yf,Y6 as Zf,Go as _f,Sx as $f,A6 as ag,Te as bg,Oe as cg,We as dg,dt as eg,ve as fg,Zo as gg,Cn as hg,bs as ig,Es as jg,Bx as kg,Tt as lg,Kh as mg,Jh as ng,Hh as og,ii as pg,Tn as qg,Yh as rg,Ah as sg,Os as tg,sn as ug,ry as vg,Zr as wg,Js as xg,Hs as yg,se as zg,Ne as Ag,oy as Bg,iy as Cg,ay as Dg,sy as Eg,dy as Fg,Ui as Gg,Ct as Hg,zn as Ig,cy as Jg,ch as Kg,Wo as Lg,xs as Mg,hs as Ng,Qo as Og,Uh as Pg,lh as Qg,fh as Rg,qr as Sg,tf as Tg,rn as Ug,ph as Vg,kr as Wg,Ls as Xg,uh as Yg,bh as Zg,Wr as _g,Eh as $g,Ar as ah,Vr as bh,mh as ch,Yt as dh,ee as eh,Rn as fh,Qn as gh,Uo as hh,td as ih,hR as jh,yR as kh,Ud as lh,Bd as mh,LR as nh,MR as oh,Od as ph,Bi as qh,cd as rh,Xs as sh,Vf as th,Zs as uh,Ny as vh,no as wh,Xt as xh,Fy as yh,Sy as zh,jn as Ah,Ei as Bh,mi as Ch,Py as Dh,_y as Eh,ze as Fh,By as Gh,Cf as Hh,Ws as Ih,Xf as Jh,Oy as Kh,Ky as Lh,Qs as Mh,zs as Nh,js as Oh,Jy as Ph,nd as Qh,io as Rh,ky as Sh,Gf as Th,Zf as Uh,Mt as Vh,kf as Wh,xi as Xh,Wy as Yh,Qf as Zh,rd as _h,tI as $h,zf as ai,nI as bi,ed as ci,rI as di,jf as ei,$t as fi,oI as gi,iI as hi,aI as ii,sI as ji,dI as ki,od as li,cI as mi,UI as ni,Ii as oi,gI as pi,wi as qi,dn as ri,Wn as si,W as ti,ow as ui,wn as vi,us as wi,Ut as xi,Ve as yi,ut as zi,d8 as Ai,sw as Bi,c8 as Ci,U8 as Di,$i as Ei,dw as Fi,l8 as Gi,Fe as Hi,uw as Ii,Ln as Ji,bw as Ki,b8 as Li,Nw as Mi,Un as Ni,Ni as Oi,fe as Pi,A as Qi,pi as Ri,Be as Si,bt as Ti,UR as Ui,tr as Vi,lR as Wi,fR as Xi,JE as Yi,Or as Zi,lT as _i,fT as $i,pT as aj,uT as bj,bT as cj,bo as dj,Gd as ej,ET as fj,mT as gj,gT as hj,xT as ij,ki as jj,P2 as kj,V_ as lj,q_ as mj,K8 as nj,qd as oj,Cd as pj,nT as qj,P_ as rj,__ as sj,lu as tj,$2 as uj,B_ as vj,O8 as wj,Oi as xj,Ki as yj,Hi as zj,nr as Aj,NR as Bj,FR as Cj,uo as Dj,vt as Ej,Vd as Fj,or as Gj,Qd as Hj,zd as Ij,Yi as Jj,Ai as Kj,qT as Lj,CT as Mj,G8 as Nj,XT as Oj,ea as Pj,hu as Qj,z_ as Rj,nB as Sj,_2 as Tj,B2 as Uj,Iu as Vj,Y2 as Wj,ZB as Xj,kB as Yj,WB as Zj,k2 as _j,Su as $j,W2 as ak,Q2 as bk,Yu as ck,ZO as dk,kO as ek,_u as fk,$O as gk,ec as hk,Bu as ik,Lo as jk,Ou as kk,tc as lk,Ku as mk,DO as nk,vO as ok,NO as pk,FO as qk,SO as rk,PO as sk,_O as tk,BO as uk,OO as vk,KO as wk,JO as xk,To as yk,qi as zk};
@@ -0,0 +1 @@
1
+ import{ck as a,dk as b,ek as c}from"../chunk-WGXUBJ4X.js";import"../chunk-NJOW7IOK.js";import"../chunk-SRAX5OIU.js";export{c as decodePngMetadata,b as encodePngMetadata,a as getTEXtChunk};