1"use strict";(self.webpackChunkdev=self.webpackChunkdev||[]).push([[5656],{1199:(t,e,n)=>{n.d(e,{V:()=>l,q:()=>i});var s=n(14041),o=n(85627),r=n(95069);const i=(0,s.createContext)([!1]),a=({loadingStatus:t})=>{const[e,n]=(0,s.useState)("tw:opacity-100"),[i,a]=(0,s.useState)(!1);if((0,s.useEffect)((()=>{t[2]&&(i&&clearTimeout(i),a(window.setTimeout((()=>{n("opacity-0")}),1650)))}),[t[2]]),!t[0])return null;let c="secondary",l=s.createElement(o.y,null);return t[2]&&(c=t[3]?"success":"error",l=t[3]?s.createElement(r.aV,{stroke:4,className:"tw:w-8 tw:h-8"}):s.createElement(r.id,{className:"tw:w-8 tw:h-8",stroke:2})),s.createElement("div",{className:"tw:fixed tw:bottom-14 tw:md:bottom-auto tw:md:top-28 tw:left-0 tw:z-50 tw:md:px-4 tw:w-full",style:{zIndex:500}},s.createElement("div",{className:`tw:w-full tw:md:max-w-2xl tw:m-auto tw:bg-${c} tw:flex tw:flex-row tw:items-center tw:gap-4 tw:p-4 tw:px-4 ${e}\n tw:transition-opacity tw:delay-[1600ms] tw:duration-300\n tw:md:rounded-lg tw:shadow tw:text-secondary-content tw:text-lg tw:lg:text-xl tw:font-medium tw:md:bg-${c}/90`},s.createElement("span",{className:"tw:shrink-0"},l),t[1]))},c=({val:t=0,max:e=1,msg:n})=>s.createElement("div",{className:"tw:flex tw:flex-col tw:gap-2 tw:w-full tw:grow-0"},n,s.createElement("progress",{className:"tw:daisy-progress tw:text-info-content",value:t,max:e})),l=({children:t})=>{const[e,n]=(0,s.useState)(!1),[o,r]=(0,s.useState)({status:[!1],setLoadingStatus:l,loading:!1,LoadingStatus:()=>s.createElement(a,{loadingStatus:[!1]}),LoadingProgress:c});function l(t){r({...o,status:t,loading:t[0]||!1,LoadingStatus:()=>s.createElement(a,{loadingStatus:t})})}return(0,s.useEffect)((()=>{o.status[2]&&(e&&clearTimeout(e),n(window.setTimeout((()=>{l([!1])}),2e3)))}),[o.status[2]]),s.createElement(i.Provider,{value:o},t)}},2980:(t,e,n)=>{n.d(e,{f:()=>s});const s={0:"Authenticate only",1:"Read access to your own patterns and measurements sets",2:"Read access to all your account data",3:"Write access to your own patterns and measurements sets",4:"Write access to all your account data",5:"Read access to patterns and measurements sets of other users",6:"Write access to patterns and measurements sets of other users",7:"Write access to all account data of other users",8:"Impersonate other users, full write access to all data"}},11969:(t,e,n)=>{n.r(e),n.d(e,{assets:()=>u,contentTitle:()=>d,default:()=>g,frontMatter:()=>p,metadata:()=>s,toc:()=>m});const s=JSON.parse('{"id":"reference/packages/react/components/uuid/readme","title":"Uuid","description":"- Components","source":"@site/docs/reference/packages/react/components/uuid/readme.mdx","sourceDirName":"reference/packages/react/components/uuid","slug":"/reference/packages/react/components/uuid/","permalink":"/reference/packages/react/components/uuid/","draft":false,"unlisted":false,"editUrl":"https://codeberg.org/freesewing/freesewing/src/branch/develop/sites/dev/docs/reference/packages/react/components/uuid/readme.mdx","tags":[],"version":"current","frontMatter":{"title":"Uuid"},"sidebar":"tutorialSidebar","previous":{"title":"Time","permalink":"/reference/packages/react/components/time/"},"next":{"title":"Ux","permalink":"/reference/packages/react/components/ux/"}}');var o=n(31085),r=n(71184),i=n(78688),a=n(86354);const c={family:"uuid",name:"Uuid",file:"packages/react/components/Uuid/index.mjs",line:17,importAs:'import { Uuid } from "@freesewing/react/components/Uuid"',desc:"A component to display a short version of a (v4) UUID",params:[{type:{names:["object"]},description:"All component props",name:"props"},{type:{names:["React.FC"]},optional:!0,defaultvalue:!1,description:"An optional framework-specific Link component",name:"props.Link"},{type:{names:["string"]},description:"The UUID",name:"props.uuid"},{type:{names:["string"]},optional:!0,defaultvalue:!1,description:"An optional href to make this into a link",name:"props.href"},{type:{names:["string"]},optional:!0,defaultvalue:!1,description:"An optional label to pass to the CopyToClipboardButton",name:"props.label"}],return:[{type:{names:["JSX.Element"]}}]};n(14041);var l=n(59427);const h=()=>(0,o.jsx)(l.s,{uuid:"08bf6a94-6dfb-4921-b359-3b5f1bc51349",label:"UUID with custom label"}),p={title:"Uuid"},d=void 0,u={},m=[{value:"Components",id:"components",level:2}
1,{value:"Uuid",id:"uuid",level:3}];function f(t){const e={a:"a",h2:"h2",h3:"h3",li:"li",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...t.components};return(0,o.jsxs)(i.Bv,{children:[(0,o.jsxs)(e.ul,{children:["\n",(0,o.jsx)(e.li,{children:(0,o.jsx)(e.a,{href:"#components",children:"Components"})}),"\n"]}),(0,o.jsx)(e.h2,{id:"components",children:"Components"}),(0,o.jsxs)(e.p,{children:["The ",(0,o.jsx)(e.strong,{children:"Uuid"})," component family provides the following components:"]}),(0,o.jsxs)(e.ul,{children:["\n",(0,o.jsx)(e.li,{children:(0,o.jsx)(e.a,{href:"#uuid",children:"Uuid"})}),"\n"]}),(0,o.jsx)(e.h3,{id:"uuid",children:"Uuid"}),(0,o.jsx)(a.F,{docs:c,example:h})]})}function g(t={}){const{wrapper:e}={...(0,r.R)(),...t.components};return e?(0,o.jsx)(e,{...t,children:(0,o.jsx)(f,{...t})}):f(t)}},16840:(t,e,n)=>{n.d(e,{f:()=>i});var s=n(14041),o=n(73570);const r={js:"Javascript",bash:"Bash commands",sh:"Shell commands",json:"JSON",yaml:"YAML"},i=({language:t="txt",children:e,raw:n=!1,title:i=!1,copy:a=!1,noCopy:c=!1})=>{e?.props?.className&&(t=e.props.className.split("-").pop());const l={className:`language-${t} hljs tw:text-base tw:lg:text-lg tw:whitespace-break-spaces tw:overflow-scroll tw:pr-4`,style:{backgroundColor:"var(--code-background-color)"}};n&&(l.dangerouslySetInnerHTML={__html:n});const h=i||(r[t]?r[t]:t);return s.createElement("div",{className:"hljs tw:my-4"},s.createElement("div",{className:"\n tw:flex tw:flex-row tw:justify-between tw:items-center tw:text-xs tw:font-medium tw:text-warning\n tw:mt-1 tw:border-b tw:border-neutral-content tw:border-opacity-25 tw:px-4 tw:py-1 tw:mb-2 tw:lg:text-sm\n "},s.createElement("span",null,h),c?null:s.createElement(o.T,{content:a||e,label:h})),s.createElement("pre",l,e))}},19970:(t,e,n)=>{n.d(e,{D:()=>s});const s={backend:"https://backend.freesewing.eu",website:"https://freesewing.eu",monorepo:"https://codeberg.org/freesewing/freesewing",codeberg:"https://codeberg.org/freesewing",social:{YouTube:"https://www.youtube.com/@freesewing",Discord:"https://discord.freesewing.org/",Instagram:"https://instagram.com/freesewing_org",Facebook:"https://www.facebook.com/groups/627769821272714/",Codeberg:"https://codeberg.org/freesewing",Reddit:"https://www.reddit.com/r/freesewing/",Mastodon:"https://freesewing.social/@freesewing",Bluesky:"https://bsky.app/profile/freesewing.org"}}},27791:(t,e,n)=>{n.d(e,{I3:()=>o,Kk:()=>s,rA:()=>r});const s=["ankle","biceps","bustFront","bustPointToUnderbust","bustSpan","chest","crossSeam","crossSeamFront","crotchDepth","heel","head","highBust","highBustFront","hips","hpsToBust","hpsToWaistBack","hpsToWaistFront","inseam","knee","neck","seat","seatBack","shoulderSlope","shoulderToElbow","shoulderToShoulder","shoulderToWrist","underbust","upperLeg","waist","waistBack","waistToArmpit","waistToFloor","waistToHips","waistToKnee","waistToSeat","waistToUnderbust","waistToUpperLeg","wrist"],o=["shoulderSlope"],r=t=>-1!==o.indexOf(t)},29203:(t,e,n)=>{n.d(e,{O:()=>s,i:()=>o});const s={levels:{readNone:0,readSome:1,readOnly:2,writeSome:3,user:4,tester:4,curator:5,bughunter:6,support:8,admin:9},base:"user"},o=["user","curator","support","admin"]},33727:(t,e,n)=>{n.d(e,{A:()=>r,z:()=>i});const s={fields:{data:{bookmarks:2,sets:1,patterns:1},info:{img:2,bio:2,email:3,username:2},settings:{consent:2,compare:3,newsletter:2,units:2,control:1},security:{apikeys:4,mfa:3,password:2},identities:{github:3,instagram:3,mastodon:3,reddit:3,twitch:3,tiktok:3,website:3}},sets:{name:1,img:1,public:3,units:1,notes:2,createdAt:2,updatedAt:2,id:4},patterns:{name:1,img:1,public:3,notes:2,createdAt:2,updatedAt:2,id:4},statuses:{0:{name:"inactive",color:"neutral"},1:{name:"active",color:"success"},"-1":{name:"paused",color:"warning"},"-2":{name:"disabled",color:"error"}}},o={core:{sa:2,paperless:2,locale:3,units:1,complete:4,expand:4,only:4,scale:4,margin:4},ui:{renderer:4,kiosk:2},views:{draft:1,measies:1,test:3,time:3,print:1,export:1,save:1,edit:4,logs:2,inspect:4,docs:1}},r={account:s,editor:o,dflt:3,flat:{...s.fields.data,...s.fields.info,...s.fields.settings,...s.fields.security,...s.fields.identities,sets:s.sets,core:o.core,ui:o.ui,views:o.views}},i={1:{title:"Keep it as simple as possible",desc:"Hides all but the most crucial features."},2:{title:"Keep it simple, but not too simple",desc:"Hides the majority of features."},3:{title:"Balance simplicity with power",desc:"Reveals the majority of features, but not all."},4:{title:"Give me all powers, but keep me safe",desc:"Reveals all features, keeps handrails and safety checks"},5:{title:"Get out of my way",desc:"Reveals all features, removes handrails and safety checks"}}},34519:(t,e,n)=>{n.d(e,{KT:()=>a,j0:()=>r,yV:()=>i});var s=n(14041),o=n(95069);const r=({children:t})=>s.createElement("div",{className:"tw:flex tw:flex-row tw:border tw:border-success tw:rounded"},s.createElement("div",{className:"tw:bg-success tw:text-success-content tw:p-1 tw:rounded-l tw:flex tw:flex-row tw:items-center"}
1,s.createElement(o.V5,{className:"tw:w-6 tw:h-6 tw:text-success-content"})),s.createElement("div",{className:"tw:p-1 tw:px-2 tw:text-sm tw:font-medium tw:bg-success/10 tw:grow tw:rounded-r mini"},t)),i=({children:t})=>s.createElement("div",{className:"tw:flex tw:flex-row tw:border tw:border-info tw:rounded"},s.createElement("div",{className:"tw:bg-info tw:text-info-content tw:p-1 tw:rounded-l tw:flex tw:flex-row tw:items-center"},s.createElement(o.oy,{className:"tw:w-6 tw:h-6 tw:text-info-content"})),s.createElement("div",{className:"tw:p-1 tw:px-2 tw:text-sm tw:font-medium tw:bg-info/10 tw:grow tw:rounded-r mini"},t)),a=({children:t})=>s.createElement("div",{className:"tw:flex tw:flex-row tw:border tw:border-warning tw:rounded"},s.createElement("div",{className:"tw:bg-warning tw:text-warning-content tw:p-1 tw:rounded-l tw:flex tw:flex-row tw:items-center"},s.createElement(o.id,{className:"tw:w-6 tw:h-6 tw:text-warning-content"})),s.createElement("div",{className:"tw:p-1 tw:px-2 tw:text-sm tw:font-medium tw:bg-warning/10 tw:grow tw:rounded-r mini"},t))},48831:(t,e,n)=>{n.d(e,{F:()=>a});var s=n(14041),o=n(50182),r=n(95069);const i={left:"tw:-translate-x-full",right:"tw:translate-x-full",top:"tw:-translate-y-full",bottom:"tw:translate-y-full"},a=({children:t=null,flex:e="row",justify:n="center",items:a="center",bg:c="neutral",bgOpacity:l="70",bare:h=!1,keepOpenOnClick:p=!1,slideFrom:d="left",fullWidth:u=!1,wide:m=!1})=>{const{clearModal:f}=(0,s.useContext)(o.V),[g,y]=(0,s.useState)("in"),w=t=>{t?.event&&t.event.stopPropagation(),y("out"),window.setTimeout(f,150)};(0,s.useEffect)((()=>{"in"===g&&y(!1)}),[g]);const x=g?`tw:lg:opacity-0 ${i[d]} tw:lg:translate-x-0 tw:lg:translate-y-0`:"tw:opacity-100 tw:translate-none";return s.createElement("div",{className:`tw:fixed tw:top-0 tw:left-0 tw:m-0 tw:p-0 tw:shadow tw:w-full tw:h-screen\n tw:transform-all tw:duration-150 ${x}\n tw:bg-${c}/${l} tw:hover:cursor-pointer\n tw:flex tw:flex-${e} tw:justify-${n} tw:items-${a} tw:lg:p-12 tw:backdrop-blur-md`,onClick:w,style:{zIndex:250}},h?t:s.createElement("div",{onClick:p?t=>{t.target.attributes.href||t.stopPropagation()}:null,className:`tw:z-30 tw:bg-base-100 tw:p-4 tw:lg:px-8 tw:lg:rounded-lg tw:lg:shadow-lg tw:max-h-full tw:overflow-auto tw:hover:cursor-default ${u?"tw:w-full":""} ${m?"tw:max-w-5xl tw:w-full":""} `},t,s.createElement("button",{className:"tw:fixed tw:bottom-2 tw:right-2 tw:daisy-btn tw:daisy-btn-neutral tw:daisy-btn-circle tw:lg:hidden",onClick:w},s.createElement(r.US,{className:"tw:w-8 tw:h-8"}))))}},49418:(t,e,n)=>{n.d(e,{qV:()=>z});var s=n(99025);const o=JSON.parse('{"id":"plugin-measurements","r":"4.6.0"}'),r={name:o.id,version:o.r,hooks:{preDraft:function({settings:t}){for(const e of t)e.measurements&&(void 0!==e.measurements.seatBack&&void 0!==e.measurements.seat&&(e.measurements.seatFront=e.measurements.seat-e.measurements.seatBack,e.measurements.seatBackArc=e.measurements.seatBack/2,e.measurements.seatFrontArc=e.measurements.seatFront/2),void 0!==e.measurements.waist&&void 0!==e.measurements.waistBack&&(e.measurements.waistFront=e.measurements.waist-e.measurements.waistBack,e.measurements.waistBackArc=e.measurements.waistBack/2,e.measurements.waistFrontArc=e.measurements.waistFront/2),void 0!==e.measurements.crossSeam&&void 0!==e.measurements.crossSeamFront&&(e.measurements.crossSeamBack=e.measurements.crossSeam-e.measurements.crossSeamFront))}}},i=r,a=JSON.parse('{"id":"plugin-mirror","r":"4.6.0"}'),c=(t,e)=>{const{x:n,y:s}=t,{x:o,y:r}=e,[i,a]=[-(r-s),o-n];return[i,a,-(i*n+a*s)]},l=(t,e)=>{const[n,s,o]=c(t,e);return t=>{const{x:e,y:r}=t,i=(s**2-n**2)*e-2*n*s*r-2*n*o,a=(n**2-s**2)*r-2*n*s*e-2*s*o,c=n**2+s**2;t.x=i/c,t.y=a/c;const l=Number(t.attributes.get("data-mirrored"));return l>0&&t.log&&t.log.warn(`Point ${t.name} was mirrored more than once (${l+1}) which can lead to hard to trace bugs`),t.attributes.set("data-mirrored",l+1),t}},h=t=>t.charAt(0).toUpperCase()+t.slice(1),p={name:a.id,version:a.r,macros:{mirror:function({mirror:t,clone:e=!0,points:n=[],paths:s=[],snippets:o=[],prefix:r="mirrored",nameFormat:i,reverse:a=!1}){const[c,p]=t,d=l(c,p);for(const l of s)if(this.paths[l]){let t=e?this.paths[l].clone():this.paths[l];t=a?t.reverse():t;const n=e?"function"==typeof i?i(l,"path"):`${r}${h(l)}`:l;for(const e of t.ops)switch(e.type){case"move":case"line":e.to=d(e.to);break;case"curve":e.to=d(e.to),e.cp1=d(e.cp1),e.cp2=d(e.cp2)}this.paths[n]=t}for(const l of n)if(this.points[l]){const t=d(e?this.points[l].clone():this.points[l]),n=e?"function"==typeof i?i(l,"point"):`${r}${h(l)}`:l;this.points[n]=t}for(const l of o)if(this.snippets[l]){const t=this.snippets[l].anchor.name,n=e?this.snippets[l].clone():this.snippets[l],s=e?"function"==typeof i?i(l,"snippet"):`${r}${h(l)}`:l;this.snippets[s]=n;const o=d(n.anchor);if(this.points[t]){const s=e?"function"==typeof i?i(t,"point"):`${r}${h(t)}`:t;this.points[s]=o,n.anchor=this.points[s]}else n.anchor=o}}},methods:{lineValues:c,mirrorGen:l}},d=p,u=JSON.parse('{"id":"plugin-transform","r":"4.6.0"}'),m=(t,e,n,s)=>(t.x=(t.x-s.x)*e+s.x,t.y=(t.y-s.y)*n+s.y,t),f={name:u.id,version:u.r,macros:{transform:function({transform:t=Object.freeze({rotate:"rotate",translate:"translate",scale:"scale"}),x:e=0,y:n,angle:s=0,c:o=new this.Point(0,0),clone:r=!0,points:i=[],paths:a=[],prefix:c="transformed_"}){void 0===n&&(n=e);for(const l of a)if(this.paths[l]){const i=r?this.paths[l].clone():this.paths[l],a=r?"function"==typeof c?c(l,"path"):`${c}${l}`:l;switch(t){case"rotate":this.paths[a]=i.rotate(s,o);break;case"translate":this.paths[a]=i.translate(e,n);break;case"scale":for(const t of i.ops)switch(t.type){case"curve":t.cp1=m(t.cp1,e,n,o),t.cp2=m(t.cp2,e,n,o);case"move":case"line":t.to=m(t.to,e,n,o)}this.paths[a]=i}}for(const l of i)if(this.points[l]){const i=r?this.points[l].clone():this.points[l],a=r?"function"==typeof c?c(l,"point"):`${c}${l}`:l;switch(t){case"rotate":this.points[a]=i.rotate(s,o);break;case"translate":this.points[a]=i.translate(e,n);break;case"scale":this.points[a]=m(i,e,n,o)}}}}},g=f,y=JSON.parse('{"id":"plugin-round","r":"4.6.0"}'),w=["start","cp1","cp2","end"],x=["path"],b={name:y.id,version:y.r,macros:{round:function(t,{points:e,paths:n,Point:s,Path:o,store:r}){const i=.55191502449,{from:a=new s(0,0),to:c=new s(666,666),via:l=new s(666,0),id:h="roun
1d",classes:p="",hide:d=!0}=t;let{radius:u=66.6}=t;const m=r.generateMacroIds(w,h),f=r.generateMacroIds(x,h),g={...m,...f},y=a.dist(l),b=c.dist(l);return(u>y||u>b)&&(u=y>b?b:y),e[g.start]=l.shiftTowards(a,u),e[g.cp1]=l.shiftTowards(a,u*(1-i)),e[g.cp2]=l.shiftTowards(c,u*(1-i)),e[g.end]=l.shiftTowards(c,u),n[g.path]=(new o).move(this.points[g.start]).curve(e[g.cp1],e[g.cp2],e[g.end]).addClass(p),d?n[g.path].hide():n[g.path].unhide(),r.storeMacroIds(t.id,{paths:f,points:m}),r.getMacroIds(t.id)}}},v=b,_=JSON.parse('{"id":"plugin-sprinkle","r":"4.6.0"}'),k={name:_.id,version:_.r,macros:{sprinkle:function(t,{snippets:e,Snippet:n,points:s}){for(let o of t.on)e[o+"-"+t.snippet]=new n(t.snippet,s[o]),t.scale&&e[o+"-"+t.snippet].attr("data-scale",t.scale),t.rotate&&e[o+"-"+t.snippet].attr("data-rotate",t.rotate)}}},M=k,E=JSON.parse('{"id":"plugin-bin-pack","r":"4.6.0"}'),P=function({maxWidth:t=1/0,maxHeight:e=1/0,strictMax:n=!1}){this.maxWidth=t,this.maxHeight=e,this.strictMax=n,this.ensureSquare=t===1/0&&e===1/0};P.prototype={fit:function(t){let e,n,s,o,r=t.length;if(0===r)return;let i=this.strictMax&&this.maxWidth<1/0?Math.max(t[0].width,this.maxWidth):t[0].width,a=this.strictMax&&this.maxHeight<1/0?this.maxHeight:t[0].height;for(this.root={x:0,y:0,width:i,height:a},e=0;e<r;e++)s=t[e],(n=this.findNode(this.root,s.width,s.height))?(o=this.splitNode(n,s.width,s.height),s.x=o.x,s.y=o.y):(o=this.growNode(s.width,s.height),s.x=o.x,s.y=o.y)},findNode:function(t,e,n){return t.used?this.findNode(t.right,e,n)||this.findNode(t.down,e,n):e<=t.width&&n<=t.height?t:null},splitNode:function(t,e,n){t.used=!0;const s=t.y+n;t.down={x:t.x,y:s,width:t.width,height:Math.min(t.height-n,this.maxHeight-s)};const o=t.x+e;return t.right={x:o,y:t.y,width:Math.min(t.width-e,this.maxWidth-o),height:n},t},growNode:function(t,e){let n=t<=this.root.width,s=e<=this.root.height;const o=this.root.width+t;let r=s&&(this.ensureSquare?this.root.height:this.maxWidth)>=o;const i=this.root.height+e;let a=n&&(this.ensureSquare?this.root.width:this.maxHeight)>=i;return r?this.growRight(t,e):a?this.growDown(t,e):s?this.growRight(t,e):n?this.growDown(t,e):null},growRight:function(t,e){let n;return this.root={used:!0,x:0,y:0,width:this.root.width+t,height:this.root.height,down:this.root,right:{x:this.root.width,y:0,width:t,height:this.root.height}},(n=this.findNode(this.root,t,e))?this.splitNode(n,t,e):null},growDown:function(t,e){let n;return this.root={used:!0,x:0,y:0,width:this.root.width,height:this.root.height+e,down:{x:0,y:this.root.height,width:this.root.width,height:e},right:this.root},(n=this.findNode(this.root,t,e))?this.splitNode(n,t,e):null}};const $={inPlace:!0},L={name:E.id,version:E.r,store:[["pack",(t,e,n)=>{const s={...$,...n.pattern.settings[0]},o=new P(s),r=s.inPlace||!1;let i=e.map((function(t){return r?t:{width:t.width,height:t.height,item:t}}));const a=i.sort((function(t,e){return e.width-t.width}))[0].width,c=s.maxWidth&&a>s.maxWidth;i=i.sort((function(t,e){return s.maxWidth&&!s.maxHeight&&c?e.width-t.width:s.maxWidth&&!s.maxHeight||s.maxHeight?e.height-t.height:e.width*e.height-t.width*t.height})),o.fit(i);const l={width:i.reduce((function(t,e){return Math.max(t,e.x+e.width)}),0),height:i.reduce((function(t,e){return Math.max(t,e.y+e.height)}),0)};return r||(l.items=i),l}]]},C=L,S=JSON.parse('{"id":"core-plugins","r":"4.6.0"}'),N=[s.Sr,i,d,v,M,g,C],A={},O={},R=[];function j(t){for(const e in t.hooks){void 0===A[e]&&(A[e]=[]);const n=t.hooks[e];if("function"==typeof n)A[e].push(n);else if("object"==typeof n)for(let t of n)A[e].push(t)}}function I(t){for(const e in t.macros)O[e]=t.macros[e]}function T(t){t.store&&R.push(...t.store)}for(const H of N)j(H),I(H),T(H);const z={name:S.id,version:S.r,store:R,hooks:A,macros:O}},50182:(t,e,n)=>{n.d(e,{V:()=>o,i:()=>r});var s=n(14041);const o=(0,s.createContext)(null),r=({children:t})=>{const[e,n]=(0,s.useState)({setModal:function(t){n({...e,modalContent:t})},clearModal:function(){n({...e,modalContent:null})},modalContent:null});return s.createElement(o.Provider,{value:e},t)}},52665:(t,e,n)=>{n.d(e,{wA:()=>r,pT:()=>jt,dd:()=>c,bR:()=>a,ZH:()=>M,Qr:()=>y,Ey:()=>N,B0:()=>it,fC:()=>g,V9:()=>_t,D4:()=>T,lL:()=>z,Wx:()=>H,U1:()=>V,VT:()=>J,rE:()=>It});var s={};n.r(s),n.d(s,{__addNonEnumProp:()=>X,__asNumber:()=>K,__isCoord:()=>Q,__macroName:()=>tt,applyTransformToPoint:()=>rt,beamIntersectsCircle:()=>w,beamIntersectsCurve:()=>k,beamIntersectsLine:()=>j,beamIntersectsX:()=>x,beamIntersectsY:()=>b,beamsIntersect:()=>v,capitalize:()=>M,cbqc:()=>y,circlesIntersect:()=>E,combineTransforms:()=>ot,curveEdge:()=>P,curveIntersectsX:()=>$,curveIntersectsY:()=>L,curveParameterFromPoint:()=>B,curvesIntersect:()=>C,deg2rad:()=>S,generateStackTransform:()=>N,getSnappedPercentageValue:()=>A,getTransformedBounds:()=>it,goldenRatio:()=>g,lineIntersectsCircle:()=>O,lineIntersectsCurve:()=>I,linesIntersect:()=>R,mergeI18n:()=>T,mergeOptions:()=>z,pctBasedOn:()=>H,pctBasedOnSa:()=>F,pointOnBeam:()=>D,pointOnCurve:()=>U,pointOnLine:()=>W,projectPointOntoCurve:()=>ct,projectPointOntoLine:()=>at,rad2deg:()=>G,round:()=>Z,snappedPctOption:()=>V,splitCurve:()=>Y,stretchToScale:()=>J,units:()=>q});var o=n(48122);class r extends o.w{reduce(){const t=this.getUtils(),e=.001;if(!(this.length()>0))return[];let n,s,o,r=0,i=[],a=[],c=this.extrema().values;for(;c[0]<e;)c.shift();for(;c[c.length-1]>.999;)c.shift();for(c.unshift(0),c.push(1),s=c[0],n=1;n<c.length;n++)r=c[n],o=this.split(s,r),o._t1=s,o._t2=r,i.push(o),s=r;
1return i.forEach((function(n){a.push(...function(n){const s=[];let o=0;if(!(n._t2-n._t1>=e))return[];if(n.simple())return[n];for(;o<1&&!n.split(o,1).simple();){let t=o+e,r=1,i=o+e;if(t>r)break;for(let e=0;e<20;e++){const s=(t+r)/2;if(n.split(o,s).simple()?(i=s,t=s):r=s,o!==i&&e>=5)break}s.push(i),o=i}s.push(1);const r=[];let i=0;for(const e of s){const s=n.split(i,e);s._t1=t.map(i,0,1,n._t1,n._t2),s._t2=t.map(e,0,1,n._t1,n._t2),r.push(s),i=e}return r}(n))})),a}}function i(){return this.list={},this}function a(t,e){this.x=t,this.y=e,this.attributes=new i}function c(){return this.hidden=!1,this.ops=[],this.attributes=new i,this.topLeft=!1,this.bottomRight=!1,this}i.prototype.add=function(t,e){return void 0===this.list[t]&&(this.list[t]=[]),this.list[t].push(e),this},i.prototype.asPropsIfPrefixIs=function(t=""){let e={},n=t.length;for(let s in this.list)if(s.substr(0,n)===t){let t=s.substr(n);"class"===t&&(t="className"),e[t]=this.get(s)}return e},i.prototype.asRenderProps=function(){const t={list:this.list,forSvg:this.render()},e=this.getAsArray("data-circle");e&&(t.circle=e,t.circleProps=this.asPropsIfPrefixIs("data-circle-"));const n=this.getAsArray("data-text");return n&&(t.text=n,t.textProps=this.asPropsIfPrefixIs("data-text-")),t},i.prototype.clone=function(){let t=new i;return t.list=JSON.parse(JSON.stringify(this.list)),t},i.prototype.get=function(t){return void 0!==this.list[t]&&this.list[t].join(" ")},i.prototype.getAsArray=function(t){return void 0!==this.list[t]&&this.list[t]},i.prototype.remove=function(t){return delete this.list[t],this},i.prototype.render=function(){let t="";for(let e in this.list)t+=` ${e}="${this.list[e].join(" ")}"`;return t},i.prototype.renderAsCss=function(){let t="";for(let e in this.list)t+=` ${e}:${this.list[e].join(" ")};`;return t},i.prototype.renderIfPrefixIs=function(t=""){let e="",n=t.length;for(let s in this.list)s.substr(0,n)===t&&(e+=` ${s.substr(n)}="${this.list[s].join(" ")}"`);return e},i.prototype.set=function(t,e){return this.list[t]=[e],this},i.prototype.setIfUnset=function(t,e){return void 0===this.list[t]&&(this.list[t]=[e]),this},a.prototype.addCircle=function(t=!1,e=!1){return t&&this.attributes.add("data-circle",t),e&&this.attributes.add("data-circle-class",e),this.__check()},a.prototype.addText=function(t="",e=!1){return this.attributes.add("data-text",t),e&&this.attributes.add("data-text-class",e),this.__check()},a.prototype.angle=function(t){let e=Math.atan2(-1*this.__check().dy(t.__check()),this.dx(t));for(;e<0;)e+=2*Math.PI;return G(e)},a.prototype.attr=function(t,e,n=!1){return n?this.attributes.set(t,e):this.attributes.add(t,e),this.__check()},a.prototype.clone=function(){this.__check();const t=new a(this.x,this.y).__withLog(this.log);return t.attributes=this.attributes.clone(),t},a.prototype.copy=function(){return new a(this.__check().x,this.y).__withLog(this.log)},a.prototype.dist=function(t){const e=this.__check().x-t.__check().x,n=this.y-t.y;return Math.hypot(e,n)},a.prototype.dx=function(t){return t.__check().x-this.__check().x},a.prototype.dy=function(t){return t.__check().y-this.__check().y},a.prototype.flipX=function(t=!1){return this.__check(),t&&(t instanceof a!=!0&&this.log.warn("Called `Point.flipX(that)` but `that` is not a `Point` object"),t.__check()),!1===t||0===t.x?new a(-1*this.x,this.y).__withLog(this.log):new a(t.x+this.dx(t),this.y).__withLog(this.log)},a.prototype.flipY=function(t=!1){return this.__check(),t&&(t instanceof a!=!0&&this.log.warn("Called `Point.flipY(that)` but `that` is not a `Point` object"),t.__check()),!1===t||0===t.y?new a(this.x,-1*this.y).__withLog(this.log):new a(this.x,t.y+this.dy(t)).__withLog(this.lo)},a.prototype.rotate=function(t,e){"number"!=typeof t&&this.log.warn("Called `Point.rotate(deg,that)` but `deg` is not a number"),e instanceof a!=!0&&this.log.warn("Called `Point.rotate(deg,that)` but `that` is not a `Point` object");const n=this.__check().dist(e.__check()),s=this.angle(e);return new a(e.x+n*Math.cos(S(s+t))*-1,e.y+n*Math.sin(S(s+t))).__withLog(this.log)},a.prototype.setCircle=function(t=!1,e=!1){return t&&this.attributes.set("data-circle",t),e&&this.attributes.set("data-circle-class",e),this.__check()},a.prototype.setText=function(t="",e=!1){return this.attributes.set("data-text",t),e&&this.attributes.set("data-text-class",e),this.__check()},a.prototype.shift=function(t,e){t=K(t,"deg","Point.shift",this.log),e=K(e,"dist","Point.shift",this.log);let n=this.__check().copy();return n.x+=e,n.rotate(t,this)},a.prototype.shiftFractionTowards=function(t,e){return t instanceof a!=!0&&this.log.warn("Called `Point.shiftFractionTowards(that, fraction)` but `that` is not a `Point` object"),"number"!=typeof e&&this.log.warn("Called `Point.shiftFractionTowards` but `fraction` is not a number"),this.__check().shiftTowards(t.__check(),this.dist(t)*e)},a.prototype.shiftOutwards=function(t,e){return e=K(e,"distance","Point.shiftOutwards",this.log),t instanceof a!=!0&&this.log.warn("Called `Point.shiftOutwards(that, distance)` but `that` is not a `Point` object"),this.__check(),t.__check(),this.__check().shiftTowards(t.__check(),this.dist(t)+e)},a.prototype.shiftTowards=function(t,e){return e=K(e,"dist","Point.shiftTowards",this.log),t instanceof a!=!0&&this.log.warn("Called `Point.shiftTowards(that, distance)` but `that` is not a `Point` object"),this.__check().shift(this.angle(t.__check()),e)},a.prototype.sitsOn=function(t){return t instanceof a!=!0&&this.log.warn("Called `Point.sitsOn(that)` but `that` is not a `Point` object"),this.__check().x===t.__check().x&&this.y===t.y},a.prototype.sitsRoughlyOn=function(t){return t instanceof a!=!0&&this.log.warn("Called `Point.sitsRoughlyOn(that)` but `that` is not a `Point` object"),Math.round(this.__check().x)===Math.round(t.__check().x)&&Math.round(this.y)===Math.round(t.y)},a.prototype.slope=function(t){return(t.__check().y-this.__check().y)/(t.x-this.x)},a.prototype.translate=function(t,e){this.__check(),"number"!=typeof t&&this.log.warn("Called `Point.translate(x,y)` but `x` is not a number"),"number"!=typeof e&&this.log.warn("Called `Point.translate(x,y)` but `y` is not a number");const n=this.copy();return n.x+=t,n.y+=e,n},a.prototype.asRenderProps=function(){return{x:this.x,y:this.y,attributes:this.attributes.asRenderProps()}},a.prototype.__check=function(){return"number"!=typeof this.x&&this.log.warn("X value of `Point` is not a number"),"number"!=typeof this.y&&this.log.warn("Y value of `Point` is not a number"),this},a.prototype.__withLog=function(t=!1){return t&&Object.defineProperty(this,"log",{value:t}),this},c.prototype._curve=function(t,e){e instanceof a!=!0&&this.log.warn("Called `Path._curve(cp2, to)` but `to` is not a `Point` object"),t instanceof a!=!0&&this.log.warn("Called `Path._curve(cp2, to)` but `cp2` is not a `Point` object");let n=this.ops.slice(-1).pop().to;return this.ops.push({type:"curve",cp1:n,cp2:t,to:e}),this},c.prototype.addClass=function(t=!1){return t&&this.attributes.add("class",t),this},c.prototype.addText=function(t="",e=!1){return this.attributes.add("data-text",t),e&&this.attributes.add("data-text-class",e),this},c.prototype.asPathstring=function(){let t="";for(let e of this.ops)switch(e.type){case"move":t+=`M ${Z(e.to.x)},${Z(e.to.y)}`;break;case"line":t+=` L ${Z(e.to.x)},${Z(e.to.y)}`;break;case"curve":t+=` C ${Z(e.cp1.x)},${Z(e.cp1.y)} ${Z(e.cp2.x)},${Z(e.cp2.y)} ${Z(e.to.x)},${Z(e.to.y)}`;break;
1case"close":t+=" z"}return t};function l(t,e){if(t&&"object"==typeof t)if("number"==typeof t.x)e.length>0&&Math.abs(t.x-e[e.length-1].x)<.001&&Math.abs(t.y-e[e.length-1].y)<.001||e.push(t);else{e.length>0&&Math.abs(t[0].x-e[e.length-1].x)<.001&&Math.abs(t[0].y-e[e.length-1].y)<.001&&t.shift();for(let n of t)e.push(n)}}function h(t,e=!1){return(new c).__withLog(e).move(new a(t.points[0].x,t.points[0].y)).curve(new a(t.points[1].x,t.points[1].y),new a(t.points[2].x,t.points[2].y),new a(t.points[3].x,t.points[3].y)).clean()}function p(t){let e=t.bbox();return{topLeft:new a(e.x.min,e.y.min),bottomRight:new a(e.x.max,e.y.max)}}function d(t){let e,n=(new c).__withLog(t[0].log).move(t[0].ops[0].to);for(let s of t)for(let t of s.ops){if("curve"===t.type)n.curve(t.cp1,t.cp2,t.to);else if("noop"===t.type)n.noop(t.id);else{if("close"===t.type){let t="Cannot join a closed path with another";throw n.log.error(t),new Error(t)}e&&!t.to.sitsRoughlyOn(e)&&n.line(t.to)}t.to&&(e=t.to)}return n}function u(t){let e=t.from,n=t.to;return e.x===n.x?e.y<n.y?{topLeft:e,bottomRight:n}:{topLeft:n,bottomRight:e}:e.y===n.y?e.x<n.x?{topLeft:e,bottomRight:n}:{topLeft:n,bottomRight:e}:e.x<n.x?e.y<n.y?{topLeft:e,bottomRight:n}:{topLeft:new a(e.x,n.y),bottomRight:new a(n.x,e.y)}:e.x>n.x?e.y<n.y?{topLeft:new a(n.x,e.y),bottomRight:new a(e.x,n.y)}:{topLeft:new a(n.x,n.y),bottomRight:new a(e.x,e.y)}:void 0}function m(t,e,n,s=!1){if(t.x===e.x&&t.y===e.y)return!1;let o=t.angle(e)-90;return(new c).__withLog(s).move(t.shift(o,n)).line(e.shift(o,n))}function f(t,e,n){let s,o,r,i,c=0;for(let l=0;l<=n;l++){if(r=l/n,o=e.get(r),o=new a(o.x,o.y),l>0){if(i=o.dist(s),c+i>t)return o;c+=i}s=o}}c.prototype.asRenderProps=function(){return{attributes:this.attributes.asRenderProps(),hidden:this.hidden,name:this.name,ops:this.ops.map((t=>(t=>{const e={type:t.type};for(const n of["from","to","cp1","cp2"])t[n]&&(e[n]=t[n].asRenderProps());return t.id&&(e.id=t.id),e})(t))),topLeft:this.topLeft,bottomRight:this.bottomRight,width:this.bottomRight.x-this.topLeft.x,height:this.bottomRight.y-this.topLeft.y,d:this.asPathstring()}},c.prototype.attr=function(t,e,n=!1){return t||this.log.warn("Called `Path.attr(name, value, overwrite=false)` but `name` is undefined or false"),void 0===e&&this.log.warn("Called `Path.attr(name, value, overwrite=false)` but `value` is undefined"),n&&this.log.debug(`Overwriting \`Path.attribute.${t}\` with ${e} (was: ${this.attributes.get(t)})`),n?this.attributes.set(t,e):this.attributes.add(t,e),this},c.prototype.bbox=function(){let t,e=[];for(let n in this.ops){let s=this.ops[n];"line"===s.type?e.push(u({from:t,to:s.to})):"curve"===s.type&&e.push(p(new r({x:t.x,y:t.y},{x:s.cp1.x,y:s.cp1.y},{x:s.cp2.x,y:s.cp2.y},{x:s.to.x,y:s.to.y}))),s.to&&(t=s.to)}return 0===e.length&&t&&e.push(u({from:t,to:t})),function(t){let e=1/0,n=-1/0,s=1/0,o=-1/0;for(let r of t)r.topLeft.x<e&&(e=r.topLeft.x),r.topLeft.y<s&&(s=r.topLeft.y),r.bottomRight.x>n&&(n=r.bottomRight.x),r.bottomRight.y>o&&(o=r.bottomRight.y);return{topLeft:new a(e,s),bottomRight:new a(n,o)}}(e)},c.prototype.circleSegment=function(t,e){const n=this.end().dist(e),s=Math.ceil(Math.abs(t/90)),o=t/s,r=S(o),i=n*(4/3)*Math.tan(r/4);for(let a=0;a<s;a++){const t=this.end(),n=t.rotate(o,e),s=t.angle(e)-90,r=n.angle(e)+90,a=t.shift(s,i),c=n.shift(r,i);this.curve(a,c,n)}return this},c.prototype.clean=function(){const t=[];let e;for(const n in this.ops){const s=this.ops[n];["move","close","noop"].includes(s.type)?t.push(s):"line"===s.type?s.to.sitsRoughlyOn(e)||t.push(s):"curve"===s.type&&(s.cp1.sitsRoughlyOn(e)&&s.cp2.sitsRoughlyOn(e)&&s.to.sitsRoughlyOn(e)||t.push(s)),e=s.to}return t.length<this.ops.length&&(this.ops=t),0!==t.length&&(1!==t.length||"move"!==t[0].type)&&this},c.prototype.clone=function(){let t=(new c).__withLog(this.log).setHidden(this.hidden);this.topLeft?t.topLeft=this.topLeft.clone():t.topLeft=!1,this.bottomRight?t.bottomRight=this.bottomRight.clone():t.bottomRight=!1,t.attributes=this.attributes.clone(),t.ops=[];for(let e in this.ops){let n=this.ops[e];t.ops[e]={type:n.type}
1,"move"===n.type||"line"===n.type?t.ops[e].to=n.to.clone():"curve"===n.type?(t.ops[e].to=n.to.clone(),t.ops[e].cp1=n.cp1.clone(),t.ops[e].cp2=n.cp2.clone()):"noop"===n.type&&(t.ops[e].id=n.id)}return t},c.prototype.close=function(){return this.ops.push({type:"close"}),this},c.prototype.combine=function(...t){return function(...t){const e=(new c).__withLog(t[0].log);for(const n of t)e.ops.push(...n.ops);return e}(this,...t)},c.prototype.curve=function(t,e,n){return n instanceof a!=!0&&this.log.warn("Called `Path.curve(cp1, cp2, to)` but `to` is not a `Point` object"),t instanceof a!=!0&&this.log.warn("Called `Path.curve(cp1, cp2, to)` but `cp1` is not a `Point` object"),e instanceof a!=!0&&this.log.warn("Called `Path.curve(cp1, cp2, to)` but `cp2` is not a `Point` object"),this.ops.push({type:"curve",cp1:t,cp2:e,to:n}),this},c.prototype.curve_=function(t,e){e instanceof a!=!0&&this.log.warn("Called `Path.curve_(cp1, to)` but `to` is not a `Point` object"),t instanceof a!=!0&&this.log.warn("Called `Path.curve_(cp1, to)` but `cp1` is not a `Point` object");let n=e.copy();return this.ops.push({type:"curve",cp1:t,cp2:n,to:e}),this},c.prototype.divide=function(){let t,e,n=[];for(let s in this.ops){let o=this.ops[s];"move"===o.type?e=o.to:"line"===o.type?o.to.sitsRoughlyOn(t)||n.push((new c).__withLog(this.log).move(t).line(o.to)):"curve"===o.type?n.push((new c).__withLog(this.log).move(t).curve(o.cp1,o.cp2,o.to)):"close"===o.type&&n.push((new c).__withLog(this.log).move(t).line(e)),o.to&&(t=o.to)}return n},c.prototype.projectPoint=function(t){if(!(t instanceof a))return this.log.error("Called `Path.projectPoint(p)` but `p` is not a `Point` object"),null;let e=this.start(),n=1/0,s=e,o=e;for(let r in this.ops){let i=this.ops[r];if("move"===i.type)o=i.to;else if("line"===i.type){let o=at(t,s,i.to),r=o.dist(t);r<n&&(n=r,e=o)}else if("curve"===i.type){let o=ct(t,s,i.cp1,i.cp2,i.to),r=o.dist(t);r<n&&(n=r,e=o)}else if("close"===i.type){let r=at(t,s,o),i=r.dist(t);i<n&&(n=i,e=r)}i.to&&(s=i.to)}return e},c.prototype.measureAlong=function(t){if(!(t instanceof a))return this.log.error("Called `Path.measureAlong(p)` but `p` is not a `Point` object"),null;let e=0,n=this.start(),s=n;for(let o in this.ops){let i=this.ops[o];if("move"===i.type)s=i.to;else if("line"===i.type){if(W(n,i.to,t))return e+=n.dist(t),e;e+=n.dist(i.to)}else if("curve"===i.type){let s=new r({x:n.x,y:n.y},{x:i.cp1.x,y:i.cp1.y},{x:i.cp2.x,y:i.cp2.y},{x:i.to.x,y:i.to.y});const o=s.project({x:t.x,y:t.y});if(o.d<1)return e+=s.split(o.t).left.length(),e;e+=s.length()}else if("close"===i.type){if(W(n,s,t))return e+=n.dist(t),e;e+=n.dist(s)}i.to&&(n=i.to)}return null},c.prototype.edge=function(t){if(this.__boundary(),"topLeft"===t)return this.topLeft;if("bottomRight"===t)return this.bottomRight;if("topRight"===t)return new a(this.bottomRight.x,this.topLeft.y);if("bottomLeft"===t)return new a(this.topLeft.x,this.bottomRight.y);{let e=t+"Op";if("move"===this[e].type)return this[e].to;if("line"===this[e].type){if("top"===t)return this.topOp.to.y<this.topOp.from.y?this.topOp.to:this.topOp.from;if("left"===t)return this.leftOp.to.x<this.leftOp.from.x?this.leftOp.to:this.leftOp.from;if("bottom"===t)return this.bottomOp.to.y>this.bottomOp.from.y?this.bottomOp.to:this.bottomOp.from;if("right"===t)return this.rightOp.to.x>this.rightOp.from.x?this.rightOp.to:this.rightOp.from}else if("curve"===this[e].type)return P(new r({x:this[e].from.x,y:this[e].from.y},{x:this[e].cp1.x,y:this[e].cp1.y},{x:this[e].cp2.x,y:this[e].cp2.y},{x:this[e].to.x,y:this[e].to.y}),t)}},c.prototype.end=function(){this.ops.length<1&&this.log.error("Called `Path.end()` but this path has no drawing operations");let t=this.ops[this.ops.length-1];return"close"===t.type?this.start():t.to},c.prototype.hide=function(){return this.hidden=!0,this},c.prototype.insop=function(t,e){t||this.log.warn("Called `Path.insop(noopI
1d, path)` but `noopId` is undefined or false"),e instanceof c!=!0&&this.log.warn("Called `Path.insop(noopId, path) but `path` is not a `Path` object");let n=this.clone();for(let s in n.ops)"noop"===n.ops[s].type&&n.ops[s].id===t&&(n.ops=n.ops.slice(0,s).concat(e.ops).concat(n.ops.slice(Number(s)+1)));return n},c.prototype.intersects=function(t){this===t&&this.log.error("You called Path.intersects(path)` but `path` and `this` are the same object");let e=[];for(let n of this.divide())for(let s of t.divide())"line"===n.ops[1].type?"line"===s.ops[1].type?l(R(n.ops[0].to,n.ops[1].to,s.ops[0].to,s.ops[1].to),e):"curve"===s.ops[1].type&&l(I(n.ops[0].to,n.ops[1].to,s.ops[0].to,s.ops[1].cp1,s.ops[1].cp2,s.ops[1].to),e):"curve"===n.ops[1].type&&("line"===s.ops[1].type?l(I(s.ops[0].to,s.ops[1].to,n.ops[0].to,n.ops[1].cp1,n.ops[1].cp2,n.ops[1].to),e):"curve"===s.ops[1].type&&l(C(n.ops[0].to,n.ops[1].cp1,n.ops[1].cp2,n.ops[1].to,s.ops[0].to,s.ops[1].cp1,s.ops[1].cp2,s.ops[1].to),e));return e},c.prototype.intersectsBeam=function(t,e){let n=[];for(let s of this.divide())"line"===s.ops[1].type?l(j(t,e,s.ops[0].to,s.ops[1].to),n):"curve"===s.ops[1].type&&l(k(t,e,s.ops[0].to,s.ops[1].cp1,s.ops[1].cp2,s.ops[1].to),n);return n},c.prototype.intersectsX=function(t){return"number"!=typeof t&&this.log.error("Called `Path.intersectsX(x)` but `x` is not a number"),this.__intersectsAxis(t,"x")},c.prototype.intersectsY=function(t){return"number"!=typeof t&&this.log.error("Called `Path.intersectsX(y)` but `y` is not a number"),this.__intersectsAxis(t,"y")},c.prototype.join=function(...t){if(t.length<1)return this.log.error("Called `Path.join(that)` but `that` is not a `Path` object"),this;if(2===t.length&&[!0,!1].includes(t[1]))return this.log.warn("`Path.join()` was called with the legacy signature passing a bool as second parameter. This is deprecated and will be removed in FreeSewing v4"),t[1]?d([this,t[0]]).close():d([this,t[0]]);let e=0;for(const n of t)n instanceof c!=!0&&this.log.error(`Called \`Path.join(paths)\` but the path with index \`${e}\` is not a \`Path\` object`),e++;return d([this,...t])},c.prototype.length=function(t=!1){let e,n,s=0;for(let o in this.ops){let i=this.ops[o];"move"===i.type?void 0===n?n=i.to:t&&(s+=e.dist(i.to)):"line"===i.type?s+=e.dist(i.to):"curve"===i.type?s+=new r({x:e.x,y:e.y},{x:i.cp1.x,y:i.cp1.y},{x:i.cp2.x,y:i.cp2.y},{x:i.to.x,y:i.to.y}).length():"close"===i.type&&(s+=e.dist(n)),i.to&&(e=i.to)}return s},c.prototype.line=function(t){return t instanceof a!=!0&&this.log.warn("Called `Path.line(to)` but `to` is not a `Point` object"),this.ops.push({type:"line",to:t}),this},c.prototype.move=function(t){return t instanceof a!=!0&&this.log.warn("Called `Path.move(to)` but `to` is not a `Point` object"),this.ops.push({type:"move",to:t}),this},c.prototype.noop=function(t=!1){return this.ops.push({type:"noop",id:t}),this},c.prototype.offset=function(t){return function(t,e,n){let s,o,i=[],a=!1,l=!1;for(let p in t.ops){let n=t.ops[p];if("line"===n.type){let o=m(s,n.to,e,t.log);o&&i.push(o)}else if("curve"===n.type){let o,a;s.sitsRoughlyOn(n.cp1)?(o=(new c).__withLog(t.log).move(s).curve(n.cp1,n.cp2,n.to),o=o.shiftAlong(o.length()>2?2:o.length()/10)):o=n.cp1,n.cp2.sitsRoughlyOn(n.to)?(a=(new c).__withLog(t.log).move(n.to).curve(n.cp2,n.cp1,s),a=a.shiftAlong(a.length()>2?2:a.length()/10)):a=n.cp2;let l=new r({x:s.x,y:s.y},{x:o.x,y:o.y},{x:a.x,y:a.y},{x:n.to.x,y:n.to.y});for(let n of l.offset(e)){const e=h(n,t.log);e&&i.push(e)}}else if("close"===n.type){let n=m(s,a,e,t.log);n&&i.push(n),l=!0}n.to&&(s=n.to),a&&"move"!==n.type||(a=s)}if(0!==i.length)o=d(i);else{let r=m(a,s,e,t.log);r?o=r:(o=(new c).move(a).line(s),n.warn("Could not properly calculate offset path, the given path is likely too short."))}return l?o.close():o}(this,t=K(t,"distance","Path.offset",this.log),this.log)},c.prototype.reverse=function(t=!1){let e,n=[],s=!1;for(let r in this.ops){let t=this.ops[r];"line"===t.type?t.to.sitsOn(e)||n.push((new c).__withLog(this.log).move(t.to).line(e)):"curve"===t.type?n.push((new c).__withLog(this.log).move(t.to).curve(t.cp2,t.cp1,e)):"close"===t.type&&(s=!0),t.to&&(e=t.to)}let o=(new c).__withLog(this.log).move(e);for(let r of n.reverse())o.end().sitsOn(r.ops[0].to)?o.ops.push(r.ops[1]):o.ops.push(...r.ops);return s&&o.close(),t&&(o.attributes=this.attributes.clone()),o},c.prototype.rotate=function(t,e,n=!1){t=K(t,"deg","Path.rotate",this.log),e instanceof a||this.log.warn("Called `Path.rotate(deg,that)` but `rotationOrigin` is not a `Point` object");const s=(new c).__withLog(this.log);for(const o of this.ops)if("move"===o.type){const n=o.to.rotate(t,e);s.move(n)}else if("line"===o.type){const n=o.to.rotate(t,e);s.line(n)}else if("curve"===o.type){const n=o.cp1.rotate(t,e),r=o.cp2.rotate(t,e),i=o.to.rotate(t,e);s.curve(n,r,i)}else"close"===o.type&&s.close();return n&&(s.attributes=this.attributes.clone()),s},c.prototype.roughLength=function(){let t,e,n=0;for(let s in this.ops){let o=this.ops[s];"move"===o.type?e=o.to:"line"===o.type?n+=t.dist(o.to):"curve"===o.type?(n+=t.dist(o.cp1),n+=o.cp1.dist(o.cp2),n+=o.cp2.dist(o.to)):"close"===o.type&&(n+=t.dist(e)),o.to&&(t=o.to)}return n},c.prototype.setClass=function(t=!1){return t&&this.attributes.set("class",t),this},c.prototype.setHidden=function(t=!1){return this.hidden=!!t,this},c.prototype.setText=function(t="",e=!1){return this.attributes.set("data-text",t),e&&this.attributes.set("data-text-class",e),this},c.prototype.shiftAlong=function(t,e=10){t=K(t,"distance","Path.shiftAlong",this.log);let n,s=0;for(let o in this.ops){let i=this.ops[o];if("line"===i.type){let e=i.to.dist(n);if(Math.abs(s+e-t)<.1)return i.to;if(s+e>t)return n.shiftTowards(i.to,t-s);s+=e}else if("curve"===i.type){let o=new r({x:n.x,y:n.y}
1,{x:i.cp1.x,y:i.cp1.y},{x:i.cp2.x,y:i.cp2.y},{x:i.to.x,y:i.to.y}),a=o.length();if(Math.abs(s+a-t)<.1)return i.to;if(s+a>t)return f(t-s,o,a*e);s+=a}n=i.to}this.log.error(`Called \`Path.shiftAlong(distance)\` with a \`distance\` of \`${t}\` but \`Path.length()\` is only \`${this.length()}\``)},c.prototype.shiftFractionAlong=function(t,e=10){return"number"!=typeof t&&this.log.error("Called `Path.shiftFractionAlong(fraction)` but `fraction` is not a number"),this.shiftAlong(this.length()*t,e)},c.prototype.smurve=function(t,e){e instanceof a!=!0&&this.log.warn("Called `Path.smurve(cp2, to)` but `to` is not a `Point` object"),t instanceof a!=!0&&this.log.warn("Called `Path.smurve(cp2, to)` but `cp2` is not a `Point` object");const n=this.ops.slice(-1).pop(),s=n.cp2.rotate(180,n.to);return this.ops.push({type:"curve",cp1:s,cp2:t,to:e}),this},c.prototype.smurve_=function(t){t instanceof a!=!0&&this.log.warn("Called `Path.smurve_(to)` but `to` is not a `Point` object");const e=this.ops.slice(-1).pop(),n=e.cp2.rotate(180,e.to),s=t;return this.ops.push({type:"curve",cp1:n,cp2:s,to:t}),this},c.prototype.split=function(t){t instanceof a!=!0&&this.log.error("Called `Path.split(point)` but `point` is not a `Point` object");let e=this.divide(),n=[],s=[];for(let o=0;o<e.length;o++){let i=e[o];if(i.ops[0].to.sitsRoughlyOn(t)){e[o].ops[0].to=t.copy(),o>0&&(e[o-1].ops[1].to=t.copy()),n=e.slice(0,o),s=e.slice(o);break}if("line"===i.ops[1].type){if(i.ops[1].to.sitsRoughlyOn(t)){o++,n=e.slice(0,o),s=e.slice(o);break}if(W(i.ops[0].to,i.ops[1].to,t)){n=e.slice(0,o),n.push((new c).__withLog(this.log).move(i.ops[0].to).line(t)),o++,s=e.slice(o),s.unshift((new c).__withLog(this.log).move(t).line(i.ops[1].to));break}}else if("curve"===i.ops[1].type){let l=B(i.ops[0].to,i.ops[1].cp1,i.ops[1].cp2,i.ops[1].to,t);if(!1!==l){let h=new r({x:i.ops[0].to.x,y:i.ops[0].to.y},{x:i.ops[1].cp1.x,y:i.ops[1].cp1.y},{x:i.ops[1].cp2.x,y:i.ops[1].cp2.y},{x:i.ops[1].to.x,y:i.ops[1].to.y}).split(l);n=e.slice(0,o),n.push((new c).__withLog(this.log).move(new a(h.left.points[0].x,h.left.points[0].y)).curve(new a(h.left.points[1].x,h.left.points[1].y),new a(h.left.points[2].x,h.left.points[2].y),t.copy())),o++,s=e.slice(o),s.unshift((new c).__withLog(this.log).move(t.copy()).curve(new a(h.right.points[1].x,h.right.points[1].y),new a(h.right.points[2].x,h.right.points[2].y),new a(h.right.points[3].x,h.right.points[3].y)));break}}}return n=n.length>0&&n[0].ops.length>1?d(n):null,s=s.length>0&&s[0].ops.length>1?d(s):null,[n,s]},c.prototype.angleAt=function(t){t instanceof a||this.log.error("Called `Path.angleAt(point)` but `point` is not a `Point` object");let e=this.divide();for(let n=0;n<e.length;n++){let s=e[n];if("line"===s.ops[1].type){if(W(s.ops[0].to,s.ops[1].to,t))return s.ops[0].to.angle(s.ops[1].to)}else if("curve"===s.ops[1].type){let e=B(s.ops[0].to,s.ops[1].cp1,s.ops[1].cp2,s.ops[1].to,t);if(!1!==e){let t=new r({x:s.ops[0].to.x,y:s.ops[0].to.y},{x:s.ops[1].cp1.x,y:s.ops[1].cp1.y},{x:s.ops[1].cp2.x,y:s.ops[1].cp2.y},{x:s.ops[1].to.x,y:s.ops[1].to.y}).normal(e);return Math.atan2(t.x,t.y)/Math.PI*180}}}return!1},c.prototype.start=function(){return(this.ops.length<1||void 0===this.ops[0].to)&&this.log.error("Called `Path.start()` but this path has no drawing operations"),this.ops[0].to},c.prototype.translate=function(t,e){"number"!=typeof t&&this.log.warn("Called `Path.translate(x, y)` but `x` is not a number"),"number"!=typeof e&&this.log.warn("Called `Path.translate(x, y)` but `y` is not a number");let n=this.clone();for(let s of n.ops)"close"!==s.type&&(s.to=s.to.translate(t,e)),"curve"===s.type&&(s.cp1=s.cp1.translate(t,e),s.cp2=s.cp2.translate(t,e));return n},c.prototype.trim=function(){let t=this.divide();for(let e=0;e<t.length;e++){let n=parseInt(e)+2,s=parseInt(t.length)-1;for(let o=n;o<s;o++){let n=t[e].intersects(t[o]);if(n.length>0){let s,i=n.pop(),l=t.slice(0,e),h=t.slice(parseInt(o)+1),p=(new c).__withLog(this.log),u=!0;for(let n of[e,o]){let e=t[n].ops;if("line"===e[1].type)p.line(i);else if("curve"===e[1].type){let t,n=new r({x:e[0].to.x,y:e[0].to.y},{x:e[1].cp1.x,y:e[1].cp1.y},{x:e[1].cp2.x,y:e[1].cp2.y},{x:e[1].to.x,y:e[1].to.y}),s=B(e[0].to,e[1].cp1,e[1].cp2,e[1].to,i),o=n.split(s);t=u?o.left:o.right,p.curve(new a(t.points[1].x,t.points[1].y),new a(t.points[2].x,t.points[2].y),new a(t.points[3].x,t.points[3].y))}u=!1}return s=l.length>0?d(l).join(p):p,h.length>0&&(s=s.join(d(h))),s.trim()}}}return this},c.prototype.unhide=function(){return this.hidden=!1,this},c.prototype.__boundary=function(){if(this.topOp)return this;let t,e=new a(1/0,1/0),n=new a(-1/0,-1/0),s=[];for(let o in this.ops){let i=this.ops[o];if("move"===i.type||"line"===i.type)i.to.x<e.x&&(e.x=i.to.x,s.leftOp=o),i.to.y<e.y&&(e.y=i.to.y,s.topOp=o),i.to.x>n.x&&(n.x=i.to.x,s.rightOp=o),i.to.y>n.y&&(n.y=i.to.y,s.bottomOp=o);else if("curve"===i.type){let a=new r({x:t.x,y:t.y}
1,{x:i.cp1.x,y:i.cp1.y},{x:i.cp2.x,y:i.cp2.y},{x:i.to.x,y:i.to.y}).bbox();a.x.min<e.x&&(e.x=a.x.min,s.leftOp=o),a.y.min<e.y&&(e.y=a.y.min,s.topOp=o),a.x.max>n.x&&(n.x=a.x.max,s.rightOp=o),a.y.max>n.y&&(n.y=a.y.max,s.bottomOp=o)}i.to&&(t=i.to)}this.topLeft=e,this.bottomRight=n;for(let o of["top","left","bottom","right"]){let t=o+"Op";this[t]=this.ops[s[t]],this[t].from="move"===this[t].type?this[t].to:this.ops[s[t]-1].to}return this},c.prototype.__intersectsAxis=function(t=!1,e){let n=[],s="x"===e?new a(t,-1e5):new a(-1e4,t),o="x"===e?new a(t,1e5):new a(1e5,t);for(let r of this.divide())"line"===r.ops[1].type?l(R(r.ops[0].to,r.ops[1].to,s,o),n):"curve"===r.ops[1].type&&l(I(s,o,r.ops[0].to,r.ops[1].cp1,r.ops[1].cp2,r.ops[1].to),n);return n},c.prototype.__withLog=function(t=!1){return t&&X(this,"log",t),this};const g=1.618034,y=.55191502449351;function w(t,e,n,s,o="x"){let r=s.x-n.x,i=s.y-n.y,c=Math.pow(r,2)+Math.pow(i,2),l=2*(r*(n.x-t.x)+i*(n.y-t.y)),h=Math.pow(n.x-t.x,2)+Math.pow(n.y-t.y,2)-Math.pow(e,2),p=Math.pow(l,2)-4*c*h;if(c<=1e-7||p<0)return!1;if(0===p){let t=-1*l/(2*c);return[new a(n.x+t*r,n.y+t*i)]}{let t=(-1*l+Math.sqrt(p))/(2*c),e=new a(n.x+t*r,n.y+t*i);t=(-1*l-Math.sqrt(p))/(2*c);let s=new a(n.x+t*r,n.y+t*i);return"x"===o&&e.x<=s.x||"y"===o&&e.y<=s.y?[e,s]:[s,e]}}function x(t,e,n){if(t.x===e.x)return!1;return v(t,e,new a(n,-10),new a(n,10))}function b(t,e,n){if(t.y===e.y)return!1;return v(t,e,new a(-10,n),new a(10,n))}function v(t,e,n,s){const o=_(t,e,n,s);return!!o&&o.p}function _(t,e,n,s){function o(t,e){return t.x*e.y-t.y*e.x}const r={x:e.x-t.x,y:e.y-t.y},i={x:s.x-n.x,y:s.y-n.y},c={x:n.x-t.x,y:n.y-t.y},l=o(r,i);if(Math.abs(l)<1e-10)return!1;const h=o(c,i)/l,p=o(c,r)/l;return{p:new a(t.x+h*r.x,t.y+h*r.y),t:h,u:p}}function k(t,e,n,s,o,i){let c=[],l=new r({x:n.x,y:n.y},{x:s.x,y:s.y},{x:o.x,y:o.y},{x:i.x,y:i.y}),h={p1:{x:t.x,y:t.y},p2:{x:e.x,y:e.y}};for(let p of r.getUtils().roots(l.points,h)){let t=l.get(p);c.push(new a(t.x,t.y))}return 0!==c.length&&(1===c.length?c[0]:c)}function M(t){return t.charAt(0).toUpperCase()+t.slice(1)}function E(t,e,n,s,o="x"){let r=t.dx(n),i=t.dy(n),c=t.dist(n);if(c>parseFloat(e)+parseFloat(s))return!1;if(c<Math.abs(parseFloat(s)-parseFloat(e)))return!1;if(0===c&&e===s)return!1;let l=(Math.pow(e,2)-Math.pow(s,2)+Math.pow(c,2))/(2*c),h=Math.sqrt(Math.pow(e,2)-Math.pow(l,2)),p=t.x+l*r/c,d=t.y+l*i/c,u=new a(p+h*i/c,d-h*r/c),m=new a(p-h*i/c,d+h*r/c);return"x"===o&&u.x<=m.x||"y"===o&&u.y<=m.y?[u,m]:[m,u]}function P(t,e,n=500){let s,o=1/0,r=1/0;"bottom"===e&&(r=-1/0),"right"===e&&(o=-1/0);for(let i=0;i<n;i++)s=t.get(i/n),("top"===e&&s.y<r||"bottom"===e&&s.y>r||"right"===e&&s.x>o||"left"===e&&s.x<o)&&(o=s.x,r=s.y);return new a(o,r)}function $(t,e,n,s,o){return I(new a(o,-1e4),new a(o,1e4),t,e,n,s)}function L(t,e,n,s,o){return I(new a(-1e4,o),new a(1e4,o),t,e,n,s)}function C(t,e,n,s,o,i,c,l){let h=[],p=new r({x:t.x,y:t.y},{x:e.x,y:e.y},{x:n.x,y:n.y},{x:s.x,y:s.y}),d=new r({x:o.x,y:o.y},{x:i.x,y:i.y},{x:c.x,y:c.y},{x:l.x,y:l.y});for(let r of p.intersects(d,.005)){let t=p.get(r.substr(0,r.indexOf("/")));h.push(new a(t.x,t.y))}if(0===h.length)return!1;if(1===h.length)return h.shift();{let t=[];for(let e of h){let n=!1;for(let s of t)e.sitsRoughlyOn(s)&&(n=!0);
1n||t.push(e)}return 1===t.length?t.shift():t}}function S(t){return t*(Math.PI/180)}function N(t=0,e=0,n=0,s=!1,o=!1,r){const i=[];let a=t||0,c=e||0,l=1,h=1;if(s&&(a+=r.topLeft.x,a+=r.bottomRight.x,l=-1),o&&(c+=r.topLeft.y,c+=r.bottomRight.y,h=-1),l+h<2&&i.push(`scale(${l}, ${h})`),n){const t={x:r.topLeft.x+r.width/2,y:r.topLeft.y+r.height/2};i.push(`rotate(${n}, ${t.x}, ${t.y})`)}return 0===a&&0===c||i.unshift(`translate(${a}, ${c})`),i}function A(t,e,n){let s=e.snap;if(!Array.isArray(s)&&s.metric&&s.imperial&&(s="imperial"===n?s.imperial:s.metric),"number"==typeof s)return Math.round(t/s)*s;if(Array.isArray(s)&&s.length>1)for(const o of s.sort(((t,e)=>t-e)).map(((t,e)=>{const n=e<s.length-1?(s[Number(e)+1]-t)/2:(t-s[e-1])/2;return{min:t-n,max:t+Number(n),snap:t}})))if(t<=o.max&&t>=o.min)return o.snap;return t}function O(t,e,n,s,o="x"){let r=w(t,e,n,s,o);if(!1===r)return!1;if(1===r.length)return!!W(n,s,r[0])&&r;{let t=r[0],e=r[1];if(!W(n,s,t,5)&&!W(n,s,e,5))return!1;if(W(n,s,t,5)&&W(n,s,e,5))return"x"===o&&t.x<=e.x||"y"===o&&t.y<=e.y?[t,e]:[e,t];if(W(n,s,t,5))return[t];if(W(n,s,e,5))return[e]}}function R(t,e,n,s){const o=_(t,e,n,s);if(!o)return!1;const r=1e-10;return!(o.t<-1e-10||o.t>1+r)&&(!(o.u<-1e-10||o.u>1+r)&&o.p)}function j(t,e,n,s){const o=_(t,e,n,s);if(!o)return!1;return!(o.u<-1e-10||o.u>1+1e-10)&&o.p}function I(t,e,n,s,o,i){let c=[],l=new r({x:n.x,y:n.y},{x:s.x,y:s.y},{x:o.x,y:o.y},{x:i.x,y:i.y}),h={p1:{x:t.x,y:t.y},p2:{x:e.x,y:e.y}};for(let r of l.intersects(h)){let t=l.get(r);c.push(new a(t.x,t.y))}return 0!==c.length&&(1===c.length?c[0]:c)}function T(t,e){const n={};for(const s of t)for(const t in s){const o=s[t];void 0===n[t]&&(n[t]={}),o.t&&(n[t].t=o.t),o.d&&(n[t].d=o.d);for(const s of"spo")if(o[s]){void 0===n[t][s]&&(n[t][s]={});for(const[r,i]of Object.entries(o[s]))et(r,e?.[s])&&(n[t][s][r]=i)}}return n}function z(t={},e){let n={};for(const[s,o]of Object.entries(e))"object"==typeof o?void 0!==o.pct?n[s]=o.pct/100:void 0!==o.mm?n[s]=o.mm:void 0!==o.deg?n[s]=o.deg:void 0!==o.count?n[s]=o.count:void 0!==o.bool?n[s]=o.bool:void 0!==o.dflt&&(n[s]=o.dflt):n[s]=o;return"object"==typeof t.options&&(n={...n,...t.options}),n}function H(t){return{toAbs:(e,{measurements:n})=>n[t]*e,fromAbs:(e,{measurements:n})=>Math.round(1e4*e/n[t])/1e4}}function F(){return{toAbs:(t,{sa:e})=>(e||10)*t,fromAbs:(t,{sa:e})=>Math.round(1e4*t/(e||10))/1e4}}function V(t,e){return{...e,toAbs:(n,{measurements:s,units:o})=>A(s[t]*n,e,o),fromAbs:(e,{measurements:n})=>Math.round(1e4*e/n[t])/1e4}}function D(t,e,n,s=1e6){if(t.sitsOn(n))return!0;if(e.sitsOn(n))return!0;let o=n.dx(t)*e.dy(t)-n.dy(t)*e.dx(t);return 0===Math.abs(Math.round(o*s)/s)}function U(t,e,n,s,o){return!1!==B(t,e,n,s,o)}function B(t,e,n,s,o){if(t.sitsOn(o))return 0;if(s.sitsOn(o))return 1;let i=new r({x:t.x,y:t.y},{x:e.x,y:e.y},{x:n.x,y:n.y},{x:s.x,y:s.y}),a=i.intersects({p1:{x:o.x-1,y:o.y},p2:{x:o.x+1,y:o.y}});return 0===a.length&&(a=i.intersects({p1:{x:o.x,y:o.y-1},p2:{x:o.x,y:o.y+1}})),a.length>0&&a.shift()}function W(t,e,n,s=1e6){if(!D(t,e,n,s))return!1;let o=t.dist(e),r=t.dist(n)+n.dist(e);return 0===Math.round(Math.abs(o-r)*s)}function G(t){return t/Math.PI*180}function Z(t){return Math.round(100*t)/100}function Y(t,e,n,s,o){let[r,i]=(new c).move(t).curve(e,n,s).split(o);return[{start:r.ops[0].to,cp1:r.ops[1].cp1,cp2:r.ops[1].cp2,end:r.ops[1].to},{start:i.ops[0].to,cp1:i.ops[1].cp1,cp2:i.ops[1].cp2,end:i.ops[1].to}]}function J(t){return 1/(1+parseFloat(t))}function q(t,e="metric"){return"imperial"===e?Z(t/25.4)+""":Z(t/10)+"cm"}function X(t,e,n){return Object.defineProperty(t,e,{enumerable:!1,configurable:!1,writable:!0,value:n}),t}function K(t,e,n,s){if("number"==typeof t)return t;if("string"==typeof t){s.warn(`Called \`${n}(${e})\` but \`${e}\` is not a number. Will attempt to cast to Number`);try{return t=Number(t)}catch{s.error(`Called \`${n}(${e})\` but \`${e}\` is not a number nor can it be cast to one`)}}else s.error(`Called \`${n}(${e})\` but \`${e}\` is not a number`);return t}function Q(t){return t==t&&"number"==typeof t}function tt(t){return`__macro_${t.toLowerCase()}`}function et(t,e){return(!e?.drop||!e.drop.includes(t))&&!(e?.keep&&!e.keep.includes(t))}function nt(t){const e=t.match(/(\w+)\(([^)]+)\)/),n=e[1],s=e[2].split(/,\s*/).map(parseFloat);return{parts:e,name:n,values:s}}function st(t,e,n){switch(t){case"matrix":e=[e[0]*n[0]+e[2]*n[1],e[1]*n[0]+e[3]*n[1],e[0]*n[2]+e[2]*n[3],e[1]*n[2]+e[3]*n[3],e[0]*n[4]+e[2]*n[5]+e[4],e[1]*n[4]+e[3]*n[5]+e[5]];break;case"translate":e[4]+=e[0]*n[0]+e[2]*n[1],e[5]+=e[1]*n[0]+e[3]*n[1];break;case"scale":e[0]*=n[0],e[1]*=n[0],e[2]*=n[1],e[3]*=n[1];break;
1case"rotate":{const t=n[0]*Math.PI/180,s=n[1],o=n[2];void 0!==s&&(e=st("translate",e,[s,o]));const r=Math.cos(t),i=Math.sin(t);e=[e[0]*r+e[2]*i,e[1]*r+e[3]*i,e[0]*-i+e[2]*r,e[1]*-i+e[3]*r,e[4],e[5]],void 0!==s&&(e=st("translate",e,[-s,-o]));break}case"skewX":e[2]+=e[0]*Math.tan(n[0]*Math.PI/180),e[3]+=e[1]*Math.tan(n[0]*Math.PI/180);break;case"skewY":e[0]+=e[2]*Math.tan(n[0]*Math.PI/180),e[1]+=e[3]*Math.tan(n[0]*Math.PI/180)}return e}function ot(t=[]){if(t.length<1)return"";let e=[1,0,0,1,0,0];for(let n=0;n<t.length;n++){const{name:s,values:o}=nt(t[n]);e=st(s,e,o)}return"matrix("+e.join(", ")+")"}function rt(t,e){const{name:n,values:s}=nt(t);let o=[1,0,0,1,0,0];o=st(n,o,s);const r=e.x*o[0]+e.y*o[2]+o[4],i=e.x*o[1]+e.y*o[3]+o[5];return e.x=r,e.y=i,e}function it(t,e=!1){if(!t.topLeft)return{};let n=t.topLeft,s=t.bottomRight,o=new a(s.x,n.y),r=new a(n.x,s.y);if(e){const t=ot(e);n=rt(t,n.copy()),s=rt(t,s.copy()),o=rt(t,o.copy()),r=rt(t,r.copy())}return{topLeft:new a(Math.min(n.x,s.x,r.x,o.x),Math.min(n.y,s.y,r.y,o.y)),bottomRight:new a(Math.max(n.x,s.x,r.x,o.x),Math.max(n.y,s.y,r.y,o.y))}}function at(t,e,n){const s=n.x-e.x,o=n.y-e.y,r=s*s+o*o;if(0===r)return e.copy();const i=((t.x-e.x)*s+(t.y-e.y)*o)/r,c=Math.max(0,Math.min(1,i));return new a(e.x+c*s,e.y+c*o)}function ct(t,e,n,s,o){const i=new r({x:e.x,y:e.y},{x:n.x,y:n.y},{x:s.x,y:s.y},{x:o.x,y:o.y}).project({x:t.x,y:t.y});return new a(i.x,i.y)}function lt(t,e,n=!1){return this.def=t,this.anchor=e,this.attributes=new i,n&&this.attributes.set("data-force",1),this}lt.prototype.attr=function(t,e,n=!1){return n?this.attributes.set(t,e):this.attributes.add(t,e),this},lt.prototype.clone=function(){let t=new lt(this.def,this.anchor.clone()).__withLog(this.log);return t.attributes=this.attributes.clone(),t},lt.prototype.scale=function(t,e=!0){return this.attr("data-scale",t,e)},lt.prototype.rotate=function(t,e=!0){return this.attr("data-rotate",t,e)},lt.prototype.asRenderProps=function(){return{def:this.def,anchor:this.anchor.asRenderProps(),attributes:this.attributes.asRenderProps()}},lt.prototype.__withLog=function(t=!1){return t&&Object.defineProperty(this,"log",{value:t}),this};var ht=n(86281),pt=n(40876),dt=n(5157);const ut=["set","setIfUnset","push","unset","get","extend"];function mt(t=[]){const e={debug:[],info:[],warn:[],error:[]};this.log={debug:function(...t){e.debug.push(...t)},info:function(...t){e.info.push(...t)},warn:function(...t){e.warn.push(...t)},error:function(...t){"undefined"!=typeof window&&console.error(...t[0]),e.error.push(...t)}},this.logs=e,this.generateMacroIds=function(t,e,n=!1){n||(n=this.get("activeMacro"));const s={};for(const o of t)s[o]=`__macro_${n}_${e}_${o}`;return s},this.storeMacroIds=function(t,e,n=!1,s=!1){n||(n=this.get("activeMacro")),s||(s=this.get("activePart")),this.set(["parts",s,"macros",n,"ids",t],e)},this.getMacroIds=function(t,e=!1,n=!1){return e||(e=this.get("activeMacro")),n||(n=this.get("activePart")),this.get(["parts",n,"macros",e.toLowerCase(),"ids",t],!1)},this.removeMacroNodes=function(t,e,n){const s=this.getMacroIds(t,e,n.name);if(s){if(s.points)for(const t of Object.values(s.points))delete n.points[t];if(s.paths)for(const t of Object.values(s.paths))delete n.paths[t]}return this.getMacroIds(t,e)},this.pack=ft;for(const[n,s]of t)-1!==ut.indexOf(n)?this.log.warn(`You cannot overwrite \`store.${n}()\``):ht(this,n,s);return this}function ft(t){let e=0;for(const n of t)n.width>e&&(e=n.width),n.height>e&&(e=n.height);return{w:e,h:0}}function gt(t,e){return t?e=Array.isArray(e)?Array.isArray(t)?[...t,...e]:[t,...e]:Array.isArray(t)?t.join(".")+e:t+e:e}mt.prototype.extend=function(t){for(const[e,n]of t)-1!==ut.indexOf(e)?this.log.warn(`You cannot overwrite \`store.${e}()\``):(this.log.debug(`Extending store with \`${e}\``),ht(this,e,((...t)=>n(this,...t))));return this},mt.prototype.get=function(t,e,n=""){t=gt(n,t);const s=dt(this,t,e);return void 0===s&&this.log.warn(`Store.get(key) on key \`${t}\`, which is undefined`),s},mt.prototype.push=function(t,...e){const n=dt(this,t);return Array.isArray(n)?this.set(t,[...n,...e]):(this.log.warn(`Store.push(value) on key \`${t}\`, but key does not hold an array`),this)},mt.prototype.set=function(t,e,n){return t=gt(n,t),void 0===e&&this.log.warn(`Store.set(value) on key \`${t}\`, but value is undefined`),ht(this,t,e),this},mt.prototype.setIfUnset=function(t,e,n=""){return t=gt(n,t),void 0===e&&this.log.warn(`Store.setIfUnset(value) on key \`${t}\`, but value is undefined`),void 0===dt(this,t)?ht(this,t,e):this},mt.prototype.unset=function(t,e=""){return pt(this,gt(e,t)),this};const yt=()=>({parts:[],data:{}});function wt(){return{preInit:[],postInit:[],preDraft:[],preSetDraft:[],prePartDraft:[],postPartDraft:[],postSetDraft:[],postDraft:[],preSample:[],postSample:[],preRender:[],preLayout:[],postLayout:[],postRender:[],insertText:[]}}var xt=n(49418);function bt(t){const e=Array.isArray(t)?t[0]:t;return e.name||e.plugin?.name||!1}function vt(t){this.store=t.store,this.plugins={},this.hooks=new wt,this.macros={},this.__storeMethods=new Set,t.designConfig.noCorePlugins||this.use(xt.qV)}vt.prototype.loadConfigPlugins=function(t,e){if(!t.plugins)return this;for(const n in t.plugins)this.use(t.plugins[n],t.plugins[n]?.data,e);return this},vt.prototype.on=function(t,e,n){for(const s of this.hooks[t])if(s.method===e)return this;return this.hooks[t].push({method:e,data:n}),this},vt.prototype.use=function(t,e,n=[{}]){const s=bt(t);return this.plugins?.[s]?(this.store.log.info(`Plugin \`${s}\` was requested, but it's already loaded. Skipping.`),this):t.plugin&&t.condition?this.__useIf(t,e,n):this.__loadPlugin(t,e)},vt.prototype.__loadPlugin=function(t,e){const n=bt(t);return this.plugins[n]=t,t.hooks&&this.__loadPluginHooks(t,e),t.macros&&this.__loadPluginMacros(t),t.store&&this.__loadPluginStoreMethods(t),this.store.log.info(`Loaded plugin \`${t.name}:${t.version}\``),this},vt.prototype.__loadPluginHooks=function(t,e){for(let n of Object.keys(this.hooks))if("function"==typeof t.hooks[n])this.on(n,t.hooks[n],e);else if(Array.isArray(t.hooks[n]))for(let s of t.hooks[n])this.on(n,s,e);return this},vt.prototype.__loadPluginMacros=function(t){for(let e in t.macros)"function"==typeof t.macros[e]&&this.__macro(e,t.macros[e])},vt.prototype.__loadPluginStoreMethods=function(t){if(Array.isArray(t.store))for(const e of t.store)this.__storeMethods.add(e);else this.store.log.warn("Plugin store methods should be an Array");return this},vt.prototype.__macro=function(t,e){return this.macros[t.toLowerCase()]=e,this},vt.prototype.__useIf=function(t,e,n=[{}]){let s=0;for(const o of n)t.condition(o)&&s++;return s>0?(this.store.log.info(`Condition met: Loaded plugin \`${t.plugin.name}:${t.plugin.version}\``),this.__loadPlugin(t.plugin,e)):this.store.log.info(`Condition not met: Skipped loading plugin \`${t.plugin.name}:${t.plugin.version}\``),this};const _t={HIDE_ALL:{self:!0,from:!0,after:!0,inherited:!0},HIDE_TREE:{from:!0,inherited:!0}};function kt(t){this.store=t.store,this.plugins={...t.designConfig.plugins||{}},this.options={...t.designConfig.options||{}},this.measurements=[...t.designConfig.measurements||[]],this.optionalMeasurements=[...t.designConfig.optionalMeasurements||[]],this.inject={},this.directDependencies={},this.resolvedDependencies={},this.parts={},this.partHide={},this.draftOrder=[],X(this,"__mutated",{optionDistance:{},partDistance:{},hideDistance:{}}),X(this,"__hiding",{from:{},after:{},inherited:{},always:{},never:{}})}kt.prototype.isPartValid=function(t){return"function"!=typeof t?.draft?(this.store.log.error("Part must have a draft() method"),!1):!!t.name||(this.store.log.error("Part must have a name"),!1)},kt.prototype.addPart=function(t){return this.isPartValid(t)&&this.__addPart([t]),this},kt.prototype.logPartDistances=function(){const t={};for(const e of Object.keys(this.parts)){const n=this.__mutated.partDistance[e];void 0===t[n]&&(t[n]=new Set),t[n].add(e)}for(const e of Object.keys(t))this.store.log.debug(`\u26aa\ufe0f Options priority __${e}__ : ${[...t[e]].map((t=>"`"+t+"`")).join(", ")}`)},kt.prototype.asConfig=function(){return{parts:this.parts,plugins:this.plugins,measurements:this.measurements,options:this.options,optionalMeasurements:this.optionalMeasurements,resolvedDependencies:this.resolvedDependencies,directDependencies:this.directDependencies,inject:this.inject,draftOrder:this.draftOrder,partHide:this.partHide}},kt.prototype.__addPart=function(t){const e=t[0];if(!this.parts[e.name]&&(this.parts[e.name]=Object.freeze(e),void 0===this.__mutated.partDistance[e.name]&&(this.__mutated.partDistance[e.name]=t.length),this.__resolvePartHiding(e),this.__resolvePartDependencies(t),this.__addPartConfig(e),1===t.length)){for(var n=this.resolvedDependencies[e.name].length-1;n>=0;n--){let t=this.resolvedDependencies[e.name][n];-1===this.draftOrder.indexOf(t)&&this.draftOrder.push(t)}this.draftOrder.push(e.name)}},kt.prototype.__addPartConfig=function(t){return this.__addPartOptions(t).__addPartMeasurements(t,!1).__addPartMeasurements(t,!0).__addPartPlugins(t)},kt.prototype.__addPartOptions=function(t){if(!t.options)return this;const e=this.__mutated.partDistance?.[t.name];
1for(const n in t.options){const s=t.options[n],o=this.__mutated.optionDistance[n];(!o||o>e)&&(this.options[n]=Object.freeze(s),this.__mutated.optionDistance[n]=e,this.store.log.debug(o?`\ud83d\udfe3 __${n}__ option overwritten by \`${t.name}\``:`\ud83d\udd35 __${n}__ option loaded from part \`${t.name}\``))}return this},kt.prototype.__addPartMeasurements=function(t,e=!1){const n=e?"optionalMeasurements":"measurements";return t[n]&&t[n].forEach((n=>{if(-1!==this.measurements.indexOf(n))return;const s=this.optionalMeasurements.indexOf(n),o=-1!==s;e&&!o&&this.optionalMeasurements.push(n),e||(this.measurements.push(n),o&&this.optionalMeasurements.splice(s,1)),this.store.log.debug(`\ud83d\udfe0 __${n}__ measurement is ${e?"optional":"required"} in \`${t.name}\``)})),this},kt.prototype.__addPartPlugins=function(t){if(!t.plugins)return this;const e=this.plugins;let n=t.plugins;Array.isArray(n)||(n=[n]);for(let s of n){const n=bt(s);if(this.store.log.debug(s.plugin?`\ud83d\udd0c Resolved __${n}__ conditional plugin in \`${t.name}\``:`\ud83d\udd0c Resolved __${n}__ plugin in \`${t.name}\``),Array.isArray(s)){s={...s[0],data:s[1]}}e[n]?s.plugin&&s.condition?e[n]?.condition?(e[n+"_"]=s,this.store.log.info(`Plugin \`${n}\` was conditionally added again. Renaming to ${n}_.`)):this.store.log.info(`Plugin \`${n}\` was requested conditionally, but is already added explicitly. Not loading.`):e[n].condition&&(e[n]=s,this.store.log.info(`Plugin \`${n}\` was explicitly added. Changing from conditional.`)):(e[n]=s,this.store.log.info(s.condition?`New plugin conditionally added: \`${n}\``:`New plugin added: \`${n}\``))}return this};const Mt=["from","after"],Et=["never","always"];function Pt(){return X(this,"freeId",0),X(this,"topLeft",!1),X(this,"bottomRight",!1),X(this,"width",!1),X(this,"height",!1),X(this,"utils",s),X(this,"layout",{move:{x:0,y:0}}),X(this,"Point",a),X(this,"Path",c),X(this,"Snippet",lt),X(this,"hooks",new wt),this.hidden=!1,this.attributes=new i,this.points={},this.paths={},this.snippets={},this.name=null,this}function $t(t){this.pattern=t}function Lt(t){this.pattern=t}function Ct(){return this.list={},this}function St(t){X(this,"openGroups",[]),X(this,"freeId",0),X(this,"prefix",'<?xml version="1.0" encoding="UTF-8" standalone="no"?>'),this.pattern=t,this.attributes=new i,this.attributes.add("xmlns","http://www.w3.org/2000/svg"),this.attributes.add("xmlns:svg","http://www.w3.org/2000/svg"),this.attributes.add("xmlns:xlink","http://www.w3.org/1999/xlink"),this.attributes.add("xml:lang",t?.settings?.[0]?.locale||"en"),this.attributes.add("xmlns:freesewing","http://freesewing.org/namespaces/freesewing"),this.attributes.add("freesewing",It),this.layout={},this.style="",this.defs=new Ct}function Nt(t=null){return X(this,"freeId",0),X(this,"layout",{move:{x:0,y:0}}),this.attributes=new i,this.parts=new Set,this.name=t,this.topLeft=!1,this.bottomRight=!1,this.width=!1,this.height=!1,this.anchor=new a(0,0),this}kt.prototype.__resolvePartHiding=function(t){let e=t.hide;if("string"==typeof e&&(e=_t[e]),!e)return;const n=this.__mutated.partDistance?.[t.name],s=this.__hiding.never[t.name]||1/0,o=this.__hiding.always[t.name]||1/0;e.self&&(s>n||o<=s)&&(this.partHide[t.name]=!0),Et.forEach(((t,s)=>{e[t]&&e[t].forEach((e=>{if((this.__hiding[Et[Math.abs(s-1)]][e]||1/0)>n){const o=this.__hiding[t][e]||1/0;this.__hiding[t][e]=Math.min(o,n),this.partHide[e]=1==s}}))})),Mt.concat("inherited").forEach((n=>{void 0===this.__hiding[n][t.name]&&(this.__hiding[n][t.name]=e[n])}))},kt.prototype.__resolvePartDependencies=function(t){const e=t[0];this.resolvedDependencies[e.name]=this.resolvedDependencies[e.name]||[],Mt.forEach((n=>{if(e[n]){const o=[].concat(e[n]);for(var s=o.length-1;s>=0;s--){const r=o[s];this.__addDependency("directDependencies",e.name,r.name),t.forEach((t=>this.__addDependency("resolvedDependencies",t.name,r.name))),this.__handlePartDependencyOfType(e,r.name,n),this.parts[r.name]?this.__resolvePartDependencies([r,...t]):this.__addPart([r,...t])}}})),this.__resolveMutatedPartDistance(e.name)},kt.prototype.__addDependency=function(t,e,n){this[t][e]=this[t][e]||[];const s=this[t][e].indexOf(n);-1!==s&&this[t][e].splice(s,1),this[t][e].push(n)},kt.prototype.__handlePartDependencyOfType=function(t,e,n){!0===this.__hiding[n][t.name]&&void 0===this.partHide[e]&&(this.partHide[e]=!0);const s=this.__hiding.inherited[t.name];"from"===n&&(this.inject[t.name]=e,this.__hiding.after[e]=s),this.__hiding.from[e]=s,this.__hiding.inherited[e]=s},kt.prototype.__resolveMutatedPartDistance=function(t){if(!this.directDependencies[t])return;let e=this.__mutated.partDistance[t]+1;this.directDependencies[t].forEach((t=>{(void 0===this.__mutated.partDistance[t]||this.__mutated.partDistance[t]<e)&&(this.__mutated.partDistance[t]=e,this.__resolveMutatedPartDistance(t))}))},Pt.prototype.asRenderProps=function(){const t={};for(const s in this.paths)t[s]=this.paths[s].asRenderProps();const e={};for(const s in this.points)e[s]=this.points[s].asRenderProps();const n={};for(const s in this.snippets)n[s]=this.snippets[s].asRenderProps();return{paths:t,points:e,snippets:n,anchor:e.anchor??new a(0,0),attributes:this.attributes.asRenderProps(),height:this.height,width:this.width,bottomRight:this.bottomRight.asRenderProps(),topLeft:this.topLeft.asRenderProps()}},Pt.prototype.attr=function(t,e,n=!1){return n?this.attributes.set(t,e):this.attributes.add(t,e),this},Pt.prototype.getId=function(t=""){return this.__getIdClosure()(t)},Pt.prototype.hide=function(){return this.hidden=!0,this},Pt.prototype.setHidden=function(t=!1){return this.hidden=!!t,this},Pt.prototype.shorthand=function(){let t=this;const e=!!this.context.settings?.complete,n=!!this.context.settings?.expand,o=!!this.context.settings?.paperless,i=this.context.settings?.sa||0,l={complete:e,context:this.context,expand:n,getId:this.__getIdClosure(),log:this.context.store.log,paperless:o,part:this,sa:i,scale:this.context.settings?.scale,store:this.context.store.extend([["pget",function(e,n,s){const o=t.context.settings.options.storePrefix?t.context.settings.options.storePrefix:t.context.store.activePart+".";t.context.store.get(n,s,o);return t.context.store.get(n,s,o)}],["pset",function(e,n,s){const o=t.context.settings.options.storePrefix?t.context.settings.options.storePrefix:t.context.store.activePart+".";return t.context.store.set(n,s,o)}]]),units:this.__unitsClosure(),utils:s,Bezier:r};var h;return l.Point=function(e,n){a.apply(this,[e,n]),Object.defineProperty(this,"log",{value:t.context.store.log})},l.Point.prototype=Object.create(a.prototype),l.Path=function(){c.apply(this,[!0]),Object.defineProperty(this,"log",{value:t.context.store.log})},l.Path.prototype=Object.create(c.prototype),l.Snippet=function(e,n){lt.apply(this,[e,n,!0]),lt.apply(this,arguments),Object.defineProperty(this,"log",{value:t.context.store.log})},l.Snippet.prototype=Object.create(lt.prototype),l.points=new Proxy(this.points,(t.points,h=t.context.store.log,{get:function(...t){return Reflect.get(...t)},set:(t,e,n)=>{n instanceof a!=1&&h.warn(`\`points.${e}\` was set with a value that is not a \`Point\` object`),null!=n.x&&Q(n.x)||h.warn(`\`points.${e}\` was set with a \`x\` parameter that is not a \`number\``),null!=n.y&&Q(n.y)||h.warn(`\`points.${e}\` was set with a \`y\` parameter that is not a \`number\``);try{n.name=e}catch(s){h.warn(`Could not set \`name\` property on \`points.${e}\``)}return t[e]=n}})),l.paths=new Proxy(this.paths,function(t,e){return{get:function(...t){return Reflect.get(...t)},set:(t,n,s)=>{s instanceof c!=1&&e.warn(`\`paths.${n}\` was set with a value that is not a \`Path\` object`);try{s.name=n}catch(o){e.warn(`Could not set \`name\` property on \`paths.${n}\``)}return t[n]=s}}}(t.paths,t.context.store.log)),l.snippets=new Proxy(this.snippets,function(t,e){return{get:function(...t){return Reflect.get(...t)},set:(t,n,s)=>{s instanceof lt!=1&&e.warn(`\`snippets.${n}\` was set with a value that is not a \`Snippet\` object`),"string"!=typeof s.def&&e.warn(`\`snippets.${n}\` was set with a \`def\` parameter that is not a \`string\``),s.anchor instanceof a!=1&&e.warn(`\`snippets.${n}\` was set with an \`anchor\` parameter that is not a \`Point\``);try{s.name=n}catch(o){e.warn(`Could not set \`name\` property on \`snippets.${n}\``)}return t[n]=s}}}(t.snippets,t.context.store.log)),l.measurements=new Proxy(this.context.settings.measurements,{get:function(e,n){return void 0===e[n]&&t.context.store.log.warn(`${t.name} tried to access \`measurements.${n}\` but it is \`undefined\``),Reflect.get(...arguments)},set:(e,n,s)=>t.context.settings.measurements[n]=s}),l.options=new Proxy(this.context.settings.options,{get:function(e,n,s){const o=t.context.store.activePart.replace(".","_")+"_"+n;return void 0===e[o]?(void 0===e[n]&&t.context.store.log.warn(`Tried to access \`options.${n}\` but it is \`undefined\``),Reflect.get(...arguments)):e[o]},set:(e,n,s)=>t.context.settings.options[n]=s}),l.absoluteOptions=new Proxy(this.context.settings.absoluteOptions,{get:function(e,n){return void 0===e[n]&&t.context.store.log.warn(`Tried to access \`absoluteOptions.${n}\` but it is \`undefined\``),Reflect.get(...arguments)},set:(e,n,s)=>t.context.settings.absoluteOptions[n]=s}),l.macro=this.__macroClosure(l),l},Pt.prototype.unhide=function(){return this.hidden=!1,this},Pt.prototype.units=function(t){return q(t,this.context.settings.units)},Pt.prototype.__boundary=function(){if(this.topLeft)return this;let t=new a(1/0,1/0),e=new a(-1/0,-1/0);for(let s in this.paths)try{let n=this.paths[s].__boundary();n.hidden||(n.topLeft.x<t.x&&(t.x=n.topLeft.x),n.topLeft.y<t.y&&(t.y=n.topLeft.y),n.bottomRight.x>e.x&&(e.x=n.bottomRight.x),n.bottomRight.y>e.y&&(e.y=n.bottomRight.y))}catch(n){return this.context.store.log.error(`Could not calculate boundary of \`paths.${s}\``),!1}for(let s in this.points){let n=this.points[s],o=n.attributes.get("data-circle");o&&(o=parseFloat(o),n.x-o<t.x&&(t.x=n.x-o),n.y-o<t.y&&(t.y=n.y-o),n.x+o>e.x&&(e.x=n.x+o),n.y+o>
1e.y&&(e.y=n.y+o))}return t.x===1/0&&(t.x=0),t.y===1/0&&(t.y=0),e.x===-1/0&&(e.x=0),e.y===-1/0&&(e.y=0),this.topLeft=t,this.bottomRight=e,this.width=this.bottomRight.x-this.topLeft.x,this.height=this.bottomRight.y-this.topLeft.y,this},Pt.prototype.__getIdClosure=function(){const t=this;return function(e=""){return t.freeId+=1,e+t.freeId}},Pt.prototype.__inject=function(t){const e=e=>{for(let n in t.points)if(t.points[n]===e)return n};this.freeId=t.freeId;for(let n in t.points)this.points[n]=t.points[n].clone();for(let n in t.paths){this.paths[n]=t.paths[n].clone();for(let s in t.paths[n].ops){let o=t.paths[n].ops[s];if("close"!==o.type){let t=e(o.to);t&&(this.paths[n].ops[s].to=this.points[t])}if("curve"===o.type){let t=e(o.cp1);t&&(this.paths[n].ops[s].cp1=this.points[t]);let r=e(o.cp2);r&&(this.paths[n].ops[s].cp2=this.points[r])}}}for(let n in t.snippets)this.snippets[n]=t.snippets[n].clone();return t.context.store.parts?.[t.name]&&(this.context.store.parts[this.name]=JSON.parse(JSON.stringify(t.context.store.parts[t.name]))),this},Pt.prototype.__macroClosure=function(t){const e=this;return function(n,s){const o=tt(n.toLowerCase());let r;if("function"==typeof e[o]){"context"in e&&(r=e.context.store.get("activeMacro",!1),e.context.store.set("activeMacro",n.toLowerCase()));const i=e[o](s,t);return"context"in e&&(r?e.context.store.set("activeMacro",r):e.context.store.unset("activeMacro")),i}"context"in e&&e.context.store.log.warn("Unknown macro `"+n.toLowerCase()+"` used in "+e.name)}},Pt.prototype.__unitsClosure=function(){const t=this;return function(e){return"number"!=typeof e&&t.context.store.log.warn(`Calling \`units(value)\` but \`value\` is not a number (\`${typeof e}\`)`),q(e,t.context.settings.units)}},$t.prototype.draft=function(){this.pattern.__runHooks("preDraft"),this.pattern.parts=[],this.pattern.__extendPatternStore();for(const t in this.pattern.settings){this.pattern.setStores[t]=this.pattern.__createSetStore(),this.__useSet(t),this.activeStore.log.debug(`\ud83d\uddc3\ufe0f Initialized store for set \`${t}\``),this.pattern.__runHooks("preSetDraft"),this.activeStore.log.debug(`\ud83d\udcd0 Drafting pattern for set \`${t}\``),this.pattern.parts[t]={},this.__loadAbsoluteOptionsSet(t);for(const e of this.pattern.config.draftOrder)this.pattern.__needs(e,t)?this.draftPartForSet(e,t):this.activeStore.log.debug(`Part \`${e}\` is not needed. Skipping part`);this.pattern.__runHooks("postSetDraft")}this.pattern.__runHooks("postDraft")},$t.prototype.draftPartForSet=function(t,e){if("__proto__"===e)throw new Error("malicious attempt at altering Object.prototype. Stopping action");this.__useSet(e),this.__createPartForSet(t,e);const n=this.pattern.config.parts?.[t];if("function"==typeof n?.draft){this.pattern.activePart=t,this.activeStore.set("activePart",t);try{this.pattern.__runHooks("prePartDraft");const s=n.draft(this.pattern.parts[e][t].shorthand());return void 0===s?this.activeStore.log.error(`Result of drafting part \`${t}\` was undefined. Did you forget to return the part?`):(this.pattern.__wants(t,e)||s.hide(),this.pattern.__runHooks("postPartDraft"),this.pattern.parts[e][t]=s),s}catch(s){this.activeStore.log.error([`Unable to draft part \`${t}\` (set \`${e}\`)`,s])}}else this.activeStore.log.error(`Unable to draft pattern part \`${t}\`. Part.draft() is not callable`)},$t.prototype.__createPartForSet=function(t,e=0){if("__proto__"===e)throw new Error("malicious attempt at altering Object.prototype. Stopping action");this.activeStore.log.debug(`\ud83d\udce6 Creating part \`${t}\` (set \`${e}\`)`),this.pattern.parts[e][t]=this.pattern.parts[e][t]||this.__createPartWithContext(t,e);const n=this.pattern.config.inject[t];if("string"==typeof n){this.activeStore.log.debug(`\ud83e\ude86 Creating part \`${t}\` from part \`${n}\``);try{this.pattern.parts[e][t].__inject(this.pattern.parts[e][n])}catch(s){this.activeStore.log.error([`Could not inject part \`${n}\` into part \`${t}\``,s])}}},$t.prototype.__createPartWithContext=function(t,e){const n=new Pt;n.name=t,n.set=e,n.stack=this.pattern.config.parts[t]?.stack||t,n.context={parts:this.pattern.parts[e],config:this.pattern.config,settings:this.pattern.settings[e],store:this.pattern.setStores[e],macros:this.pattern.plugins.macros},this.pattern.settings[e]?.partClasses&&n.attr("class",this.pattern.settings[e].partClasses);for(const s in this.pattern.plugins.macros)n[tt(s)]=this.pattern.plugins.macros[s];return n},$t.prototype.__loadAbsoluteOptionsSet=function(t){for(const e in this.pattern.settings[t].options){const n=this.pattern.config.options[e];if(void 0!==n&&n.toAbs instanceof Function)if(void 0!==n.snap)this.pattern.settings[t].absoluteOptions[e]=this.__snappedPercentageOption(e,t),this.pattern.setStores[t].log.debug(`\ud83e\uddf2 Snapped __${e}__ to \`${this.pattern.settings[t].absoluteOptions[e]}\` for set __${t}__`);else{const s=n.toAbs(this.pattern.settings[t].options[e],this.pattern.settings[t],z(this.pattern.settings[t],this.pattern.config.options));this.pattern.settings[t].absoluteOptions[e]=s,this.pattern.setStores[t].log.debug(`\ud83e\uddee Absolute value of \`${e}\` option is \`${s}\` for set __${t}__`)}}return this},$t.prototype.__snappedPercentageOption=function(t,e){const n=this.pattern.config.options[t];return A(n.toAbs(this.pattern.settings[e].options[t],this.pattern.settings[e],z(this.pattern.settings[e],this.pattern.config.options)),n,this.pattern.settings[e].units)}
1,$t.prototype.__useSet=function(t=0){this.pattern.activeSet=t,this.activeStore=this.pattern.setStores[t]},Lt.prototype.sampleMeasurement=function(t){return this.pattern.store.log.debug(`Sampling measurement \`${t}\``),this.pattern.__runHooks("preSample"),this.pattern.__applySettings(this.__measurementSets(t)),this.pattern.__init(),this.pattern.__runHooks("postSample"),this.pattern.draft()},Lt.prototype.sampleModels=function(t,e=!1){return this.pattern.store.log.debug(`Sampling models \`${Object.keys(t).join(", ")}\``),this.pattern.__runHooks("preSample"),this.pattern.__applySettings(this.__modelSets(t,e)),this.pattern.__init(),this.pattern.__runHooks("postSample"),this.pattern.draft()},Lt.prototype.sampleOption=function(t){return this.pattern.store.log.debug(`Sampling option \`${t}\``),this.pattern.__runHooks("preSample"),this.pattern.__applySettings(this.__optionSets(t)),this.pattern.__init(),this.pattern.__runHooks("postSample"),this.pattern.draft()},Lt.prototype.__listBoolOptionSets=function(t){let e=this.pattern.config.options[t];const n=this.__setBase(),s=[];let o=1;void 0!==e.bool&&(e={list:[!1,!0]});for(const r of e.list){const e={...n,options:{...n.options},idPrefix:`sample-${o}`,partClasses:`sample-${o}`};e.options[t]=r,s.push(e),o++}return s},Lt.prototype.__measurementSets=function(t){let e=this.pattern.settings[0].measurements[t];void 0===e&&this.pattern.store.log.error(`Cannot sample measurement \`${t}\` because it's \`undefined\``);let n=e/50;e*=.9;const s=[],o=this.__setBase();for(let r=1;r<11;r++){const i={...o,measurements:{...o.measurements},idPrefix:`sample-${r}`,partClasses:`sample-${r}`};i.measurements[t]=e,s.push(i),e+=n}return s},Lt.prototype.__modelSets=function(t,e=!1){const n=[],s=this.__setBase();let o=1;e&&(n.push({...s,measurements:t[e],idPrefix:`sample-${o}`,partClasses:`sample-${o} sample-focus`}),o++,delete t[e]);for(const r of Object.values(t))n.push({...s,measurements:r,idPrefix:`sample-${o}`,partClasses:`sample-${o}`});return n},Lt.prototype.__optionSets=function(t){const e=[];if(!(t in this.pattern.config.options))return e;let n=this.pattern.config.options[t];if("object"==typeof n.list||void 0!==n.bool)return this.__listBoolOptionSets(t);let s,o,r=1,i=10,a=i-1;if(void 0===n.min||void 0===n.max){n={min:.9*n,max:1.1*n}}if(void 0!==n.pct&&(r=100),o=n.min/r,void 0!==n.count||void 0!==n.mm){const t=n.max-n.min+1;t<10&&(i=t,a=Math.max(i-1,1))}s=(n.max/r-o)/a;const c=this.__setBase(),l=void 0!==n.count||void 0!==n.mm;for(let h=1;h<=i;h++){const n={...c,options:{...c.options},idPrefix:`sample-${h}`,partClasses:`sample-${h}`};n.options[t]=l?Math.ceil(o):o,e.push(n),o+=s}return e},Lt.prototype.__setBase=function(){return{measurements:{},options:{},...this.pattern.settings[0]}},Ct.prototype.clone=function(){let t=new Ct;return t.list=JSON.parse(JSON.stringify(this.list)),t},Ct.prototype.get=function(t){return void 0!==this.list[t]&&this.list[t]},Ct.prototype.remove=function(t){return delete this.list[t],this},Ct.prototype.render=function(){let t="";for(let e in this.list)t+=` ${e}="${this.list[e]}"`;return t},Ct.prototype.set=function(t,e){return this.list[t]=e,this},Ct.prototype.setIfUnset=function(t,e){return void 0===this.list[t]&&(this.list[t]=e),this},Ct.prototype.asRenderProps=function(){return{list:this.list,forSvg:this.render()}},St.prototype.asRenderProps=function(){return{attributes:this.attributes.asRenderProps(),layout:this.layout,style:this.style,defs:this.defs.asRenderProps()}},St.prototype.render=function(){this.idPrefix=this.pattern?.settings?.[0]?.idPrefix||"fs-",this.__runHooks("preRender"),this.pattern.settings[0].embed||(this.attributes.add("width",Z(this.pattern.width)+"mm"),this.attributes.add("height",Z(this.pattern.height)+"mm")),this.attributes.add("viewBox",`0 0 ${Z(this.pattern.width)} ${Z(this.pattern.height)}`),this.head=this.__renderHead(),this.tail=this.__renderTail(),this.svg="",this.layout={},this.activeStackIndex=0;for(let t in this.pattern.stacks){this.activeStack=t,this.idPrefix=this.pattern.settings[this.activeStackIndex]?.idPrefix||"fs-";const e=this.pattern.stacks[t];if(!this.pattern.__isStackHidden(t)){const n=this.__renderStack(e);this.layout[t]={svg:n,transform:e.attributes.getAsArray("transform")},this.svg+=this.__openGroup(`${this.idPrefix}stack-${t}`,e.attributes),this.svg+=n,this.svg+=this.__closeGroup()}this.activeStackIndex++}return this.svg=this.prefix+this.__renderSvgTag()+this.head+this.svg+this.tail,this.__runHooks("postRender"),this.svg}
1,St.prototype.__closeGroup=function(){return this.__outdent(),`${this.__nl()}</g>${this.__nl()}\x3c!-- end of group #${this.openGroups.pop()} --\x3e`},St.prototype.__escapeText=function(t){return Array.isArray(t)?t.map((t=>t?t.replace(/"/g,"“"):"")).join(" "):t.replace(/"/g,"“")},St.prototype.__getId=function(){return this.freeId+=1,""+this.freeId},St.prototype.__indent=function(){return this.tabs+=1,this},St.prototype.__insertText=function(t){if(this.hooks.insertText.length>0)for(let e of this.hooks.insertText)t=e.method(this.pattern.settings[this.pattern.activeSet].locale||"en",t,e.data,this.pattern);return t},St.prototype.__nl=function(){return"\n"+this.__tab()},St.prototype.__outdent=function(){return this.tabs-=1,this},St.prototype.__openGroup=function(t,e=!1){let n=this.__nl()+this.__nl();return n+=`\x3c!-- Start of group #${t} --\x3e`,n+=this.__nl(),n+=`<g id="${t}"`,e&&(n+=` ${e.render()}`),n+=">",this.__indent(),this.openGroups.push(t),n},St.prototype.__renderCircle=function(t){return`<circle cx="${Z(t.x)}" cy="${Z(t.y)}" r="${t.attributes.get("data-circle")}" ${t.attributes.renderIfPrefixIs("data-circle-")}></circle>`},St.prototype.__renderDefs=function(){let t="<defs>";return this.__indent(),t+=this.__nl()+this.defs.render(),this.__outdent(),t+=this.__nl()+"</defs>"+this.__nl(),t},St.prototype.__renderHead=function(){let t=this.__renderStyle();return t+=this.__renderDefs(),t+=this.__openGroup(this.idPrefix+"container"),t},St.prototype.__renderPath=function(t){return t.attributes.get("id")||t.attributes.add("id",this.idPrefix+this.__getId()),t.attributes.set("d",t.asPathstring()),`${this.__nl()}<path ${t.attributes.render()} />${this.__renderPathText(t)}`},St.prototype.__renderPathText=function(t){let e=t.attributes.getAsArray("data-text");if(!e)return"";this.text=this.__insertText(e);let n=t.attributes.renderIfPrefixIs("data-text-"),s="",o=t.attributes.get("data-text-class");o&&o.indexOf("center")>-1?s=' startOffset="50%" ':o&&o.indexOf("right")>-1&&(s=' startOffset="100%" ');let r=this.__nl()+"<text>";return this.__indent(),r+=`<textPath xlink:href="#${t.attributes.get("id")}" ${s}><tspan ${n}>${this.__escapeText(this.text)}</tspan></textPath>`,this.__outdent(),r+=this.__nl()+"</text>",r},St.prototype.__renderPart=function(t){const e=t.attributes.clone();e.add("transform",`translate(${-t.asRenderProps().anchor.x}, ${-t.asRenderProps().anchor.y})`);let n=this.__openGroup(`${this.idPrefix}stack-${this.activeStack}-part-${t.name}`,e);for(let s in t.paths){let e=t.paths[s];e.hidden||(n+=this.__renderPath(e))}for(let s in t.points)t.points[s].attributes.get("data-text")&&(n+=this.__renderText(t.points[s])),t.points[s].attributes.get("data-circle")&&(n+=this.__renderCircle(t.points[s]));for(let s in t.snippets){let e=t.snippets[s];n+=this.__renderSnippet(e,t)}return n+=this.__closeGroup(),n},St.prototype.__renderSnippet=function(t){if(!this.pattern.settings[0].complete&&!t.attributes.get("data-force"))return"";let e=Z(t.anchor.x),n=Z(t.anchor.y),s=t.attributes.get("data-scale")||1;s*=this.pattern.settings.scale||1,s&&(t.attributes.add("transform",`translate(${e}, ${n})`),t.attributes.add("transform",`scale(${s})`),t.attributes.add("transform",`translate(${-1*e}, ${-1*n})`));let o=t.attributes.get("data-rotate");o&&t.attributes.add("transform",`rotate(${o}, ${e}, ${n})`);let r=this.__nl();return r+=`<use x="${e}" y="${n}" `,r+=`xlink:href="#${t.def}" ${t.attributes.render()}>`,r+="</use>",r},St.prototype.__renderStack=function(t){let e="";for(const n of t.parts)e+=this.__renderPart(n);return e},St.prototype.__renderStyle=function(){let t='<style type="text/css"> <![CDATA[ ';return this.__indent(),t+=this.__nl()+this.style,this.__outdent(),t+=this.__nl()+"]]>"+this.__nl()+"</style>"+this.__nl(),t},St.prototype.__renderSvgTag=function(){let t="<svg";return this.__indent(),t+=this.__nl()+this.attributes.render(),this.__outdent(),t+=this.__nl()+">"+this.__nl(),t},St.prototype.__renderTail=function(){let t="";return t+=this.__closeGroup(),t+=this.__nl()+"</svg>",t},St.prototype.__renderText=function(t){let e=t.attributes.getAsArray("data-text");if(!1!==e){let t="";for(let n of e)this.text=this.__insertText(n),t+=this.text+" ";this.text=this.__insertText(t)}t.attributes.set("data-text-x",Z(t.x)),t.attributes.set("data-text-y",Z(t.y));let n=t.attributes.get("data-text-lineheight")||6*(this.pattern.settings.scale||1);t.attributes.remove("data-text-lineheight");let s=`${this.__nl()}<text ${t.attributes.renderIfPrefixIs("data-text-")}>`;if(this.__indent(),-1!==this.text.indexOf("\n")){let e=this.text.split("\n");s+=`<tspan>${e.shift()}</tspan>`;for(let o of e)s+=`<tspan x="${Z(t.x)}" dy="${n}">${o}</tspan>`}else s+=`<tspan>${this.__escapeText(this.text)}</tspan>`;
1return this.__outdent(),s+=this.__nl()+"</text>",s},St.prototype.__runHooks=function(t,e=!1){!1===e&&(e=this);let n=this.hooks[t];if(n.length>0)for(let s of n)s.method(e,s.data)},St.prototype.__tab=function(){let t="";for(let e=0;e<this.tabs;e++)t+=" ";return t},Nt.prototype.addPart=function(t){return t&&this.parts.add(t),this},Nt.prototype.asRenderProps=function(){return{name:this.name,attributes:this.attributes.asRenderProps(),topLeft:this.topLeft,bottomRight:this.bottomRight,width:this.width,height:this.height,parts:[...this.parts].map((t=>t.asRenderProps()))}},Nt.prototype.getPartList=function(){return[...this.parts]},Nt.prototype.getPartNames=function(){return[...this.parts].map((t=>t.name))},Nt.prototype.home=function(){if(this.topLeft)return this;this.topLeft=new a(1/0,1/0),this.bottomRight=new a(-1/0,-1/0);for(const e of this.getPartList()){e.__boundary();let t=e.points?.anchor,n=e;t&&(n={topLeft:e.topLeft.translate(-t.x,-t.y),bottomRight:e.bottomRight.translate(-t.x,-t.y)});const{topLeft:s,bottomRight:o}=it(n,e.attributes.getAsArray("transform"));s&&(this.topLeft.x=Math.min(this.topLeft.x,s.x),this.topLeft.y=Math.min(this.topLeft.y,s.y),this.bottomRight.x=Math.max(this.bottomRight.x,o.x),this.bottomRight.y=Math.max(this.bottomRight.y,o.y))}this.topLeft.x===1/0&&(this.topLeft.x=0),this.topLeft.y===1/0&&(this.topLeft.y=0),this.bottomRight.x===-1/0&&(this.bottomRight.x=0),this.bottomRight.y===-1/0&&(this.bottomRight.y=0);let t=0;for(const e in this.context.settings)this.context.settings[e].margin>t&&(t=this.context.settings[e].margin),this.context.settings[e].paperless&&t<10&&(t=10);return this.topLeft.x-=t,this.topLeft.y-=t,this.bottomRight.x+=t,this.bottomRight.y+=t,this.width=this.bottomRight.x-this.topLeft.x,this.height=this.bottomRight.y-this.topLeft.y,this.width=this.bottomRight.x-this.topLeft.x,this.height=this.bottomRight.y-this.topLeft.y,this.anchor=new a(0,0),this.topLeft.x===this.anchor.x&&this.topLeft.y===this.anchor.y||(this.attr("transform",`translate(${this.anchor.x-this.topLeft.x}, ${this.anchor.y-this.topLeft.y})`),this.layout.move.x=this.anchor.x-this.topLeft.x,this.layout.move.y=this.anchor.y-this.topLeft.y),this},Nt.prototype.getAnchor=function(){let t=!0,e=!0;const n=this.getPartList();for(const s of n)void 0===s.points.anchor&&(t=!1),void 0===s.points.gridAnchor&&(e=!1);return t?n[0].points.anchor:e?n[0].points.gridAnchor:new a(0,0)},Nt.prototype.attr=function(t,e,n=!1){return n?this.attributes.set(t,e):this.attributes.add(t,e),this},Nt.prototype.generateTransform=function(t){const{move:e,rotate:n,flipX:s,flipY:o}=t,r=N(e?.x,e?.y,n,s,o,this);return this.attributes.remove("transform"),r.forEach((t=>this.attr("transform",t))),this};function At(t){this.pattern=t,this.autoLayout=t.autoLayout}At.prototype.render=function(){return this.__startRender(),this.pattern.svg=this.svg,this.svg.render()},At.prototype.getRenderProps=function(){this.pattern.store.log.info("Gathering render props"),this.__startRender(),this.svg.__runHooks("preRender");const t={svg:this.svg.asRenderProps(),width:this.pattern.width,height:this.pattern.height,autoLayout:this.pattern.autoLayout,settings:this.pattern.settings,stacks:{}};for(let e in this.pattern.stacks)this.pattern.__isStackHidden(e)?this.pattern.store.log.info(`Stack ${e} is hidden. Skipping in render props.`):t.stacks[e]=this.pattern.stacks[e].asRenderProps();return this.svg.__runHooks("postRender"),t},At.prototype.__startRender=function(){return this.svg=new St(this.pattern),this.svg.hooks=this.pattern.plugins.hooks,this.__pack(),this},At.prototype.__stack=function(){this.stacks={};const t=this.pattern.settings;for(const e in t)for(const[n,s]of Object.entries(this.pattern.parts[e])){const o=t[e].stackPrefix+("function"==typeof s.stack?s.stack(t[e],n):s.stack);void 0===this.stacks[o]&&(this.stacks[o]=this.__createStackWithContext(o,e)),this.stacks[o].addPart(s)}this.pattern.stacks=this.stacks},At.prototype.__pack=function(){this.pattern.__runHooks("preLayout");const{settings:t,setStores:e,activeSet:n}=this.pattern;for(const r in t)if(e[r].logs.error.length>0)return e[r].log.warn("One or more errors occured. Not packing pattern parts"),this;this.__stack();let s=[];for(const[r,i]of Object.entries(this.stacks))i.attributes.remove("transform"),this.pattern.__isStackHidden(r)||(i.home(),!0===t[n].layout&&s.push({id:r,width:i.width,height:i.height}));if(!0===t[n].layout){const t=s.length>0?this.pattern.store.pack(s,this):{width:0,height:0};this.autoLayout.width=t.width,this.autoLayout.height=t.height;for(let e of s){let t=this.stacks[e.id];this.autoLayout.stacks[e.id]={move:{x:e.x+t.layout.move.x,y:e.y+t.layout.move.y}}}}const o="object"==typeof t[n].layout?t[n].layout:this.autoLayout;this.width=o.width,this.height=o.height;
1for(let r of Object.keys(o.stacks))if(this.stacks[r]){let t=o.stacks[r];this.stacks[r].generateTransform(t)}return this.pattern.width=this.width,this.pattern.height=this.height,this.pattern.autoLayout=this.autoLayout,this.pattern.__runHooks("postLayout"),this},At.prototype.__createStackWithContext=function(t){const e=new Nt;return e.name=t,e.context={config:this.pattern.config,settings:this.pattern.settings,setStores:this.pattern.setStores},e};var Ot=n(68290);function Rt(t={}){return this.designConfig=Ot(t),this.config={},this.store=new mt,this.setStores=[],X(this,"width",0),X(this,"height",0),X(this,"autoLayout",{stacks:{}}),X(this,"is",""),X(this,"Point",a),X(this,"Path",c),X(this,"Snippet",lt),X(this,"Attributes",i),X(this,"__initialized",!1),X(this,"config.parts",{}),X(this,"config.resolvedDependencies",{}),X(this,"plugins",new vt(this)),X(this,"__configResolver",new kt(this)),this}function jt(t){t={...yt(),...t};const e=function(...e){return Rt.call(this,t),this.__applySettings(e)};return(e.prototype=Object.create(Rt.prototype)).constructor=e,e.designConfig=t,e.patternConfig=(new e).getConfig(),e}Rt.prototype.addPart=function(t,e=!0){return this.__configResolver.isPartValid(t)&&!this.designConfig.parts.find((e=>e.name==t.name))&&(this.store.log.debug(`Adding Part \`${t.name}\` at runtime`),this.designConfig.parts.push(t),e&&this.__configResolver.addPart(t)),this},Rt.prototype.getConfig=function(){return this.__init().config},Rt.prototype.on=function(t,e,n){return this.plugins.on(t,e,n),this},Rt.prototype.use=function(t,e){return this.plugins.use(t,e,this.settings),this},Rt.prototype.draft=function(){return this.__init(),new $t(this).draft(),this},Rt.prototype.draftPartForSet=function(t,e){return this.__init(),new $t(this).draftPartForSet(t,e)},Rt.prototype.render=function(){return new At(this).render()},Rt.prototype.getRenderProps=function(){return new At(this).getRenderProps()},Rt.prototype.getLogs=function(){return{pattern:this.store.logs,sets:this.setStores.map((t=>t.logs))}},Rt.prototype.sample=function(){this.__init();const t=this.settings[0].sample;return"option"===t.type?this.sampleOption(t.option):"measurement"===t.type?this.sampleMeasurement(t.measurement):"models"===t.type?this.sampleModels(t.models,t.focus||!1):this.draft()},Rt.prototype.sampleMeasurement=function(t){return new Lt(this).sampleMeasurement(t)},Rt.prototype.sampleModels=function(t,e=!1){return new Lt(this).sampleModels(t,e)},Rt.prototype.sampleOption=function(t){return new Lt(this).sampleOption(t)},Rt.prototype.__applySettings=function(t){if(!Array.isArray(t))throw"Sets should be an array of settings objects";0===t.length&&t.push({}),this.settings=[];for(let e=0;e<t.length;e++){const n={...t[e]};n.options||(n.options={}),n.measurements||(n.measurements={}),this.settings.push({complete:!0,expand:!0,idPrefix:"fs-",stackPrefix:"",locale:"en",units:"metric",margin:2,scale:1,layout:!0,options:{},absoluteOptions:{},measurements:{},...n,options:{...n.options},measurements:{...n.measurements}})}return this},Rt.prototype.__extendPatternStore=function(){return this.store.extend([...this.plugins.__storeMethods]),this.store},Rt.prototype.__createSetStore=function(){const t=new mt;return t.set("data",this.store.data),t.extend([...this.plugins.__storeMethods]),t},Rt.prototype.__init=function(){return this.__initialized||(this.__runHooks("preInit"),this.store.log.info(`New \`${this.designConfig.data?.name||"No Name"}:${this.designConfig.data?.version||"No version"}\` pattern using \`@freesewing/core:${It}\``),this.designConfig.parts.forEach((t=>this.__configResolver.addPart(t))),this.__configResolver.logPartDistances(),this.config=this.__configResolver.asConfig(),this.plugins.loadConfigPlugins(this.config,this.settings),this.designConfig.data&&this.store.set("data",this.designConfig.data),this.__loadOptionDefaults(),this.store.log.info(`Pattern initialized. Draft order is: ${this.config.draftOrder.map((t=>`\`${t}\``)).join(", ")}`),this.__runHooks("postInit"),this.__initialized=!0),this},Rt.prototype.__loadOptionDefaults=function(){if(this.config.options||(this.config.options={}),Object.keys(this.config.options).length<1)return this;for(const t in this.settings)for(const[e,n]of Object.entries(this.config.options))if(void 0===this.settings[t].options[e])if("object"==typeof n)if(void 0!==n.pct)this.settings[t].options[e]=n.pct/100;else if(void 0!==n.mm)this.settings[t].options[e]=n.mm;else if(void 0!==n.deg)this.settings[t].options[e]=n.deg;else if(void 0!==n.count)this.settings[t].options[e]=n.count;else if(void 0!==n.bool)this.settings[t].options[e]=n.bool;else{if(void 0===n.dflt){let t="Unknown option type: "+JSON.stringify(n);throw this.store.log.error(t),new Error(t)}this.settings[t].options[e]=n.dflt}else this.settings[t].options[e]=n;return this},Rt.prototype.__runHooks=function(t,e=!1){!1===e&&(e=this);let n=this.plugins.hooks[t];if(n.length>0){this.store.log.debug(`\ud83e\ude9d Running \`${t}\` hooks`);for(let t of n)t.method(e,t.data)}},Rt.prototype.__isPartHidden=function(t){const e=this.parts?.[this.activeSet]?.[t]?.hidden||!1;return Array.isArray(this.settings[this.activeSet||0].only)&&this.settings[this.activeSet||0].only.includes(t)?e:!!this.config.partHide?.[t]||e},Rt.prototype.__isStackHidden=function(t){if(!this.stacks[t])return!0;const e=this.stacks[t].getPartNames();for(const n of e)if(!this.__isPartHidden(n))return!1;return!0},Rt.prototype.__needs=function(t,e=0){if(void 0===this.settings[e].only||!1===this.settings[e].only||Array.isArray(this.settings[e].only)&&0===this.settings[e].only.length)return!0;const n="string"==typeof this.settings[e].only?[this.settings[e].only]:this.settings[e].only;for(const s of n){if(s===t)return!0;
1if(-1!==this.config.resolvedDependencies[s]?.indexOf(t))return!0}return!1},Rt.prototype.__wants=function(t,e=0){if(this.__isPartHidden(t))return!1;if("string"==typeof this.settings[e].only)return this.settings[e].only===t;if(Array.isArray(this.settings[e].only)){for(const n of this.settings[e].only)if(n===t)return!0;return!1}return!0};const It="4.6.0"},56702:(t,e,n)=>{n.d(e,{MX:()=>r,N_:()=>i,hB:()=>l,sn:()=>c});var s=n(14041),o=n(86560);const r=({children:t,id:e="",title:n=!1})=>s.createElement("a",{href:`#${e}`,className:o.lD,title:n||""},t),i=({children:t,className:e=o.lD,href:n,style:r={},target:i,title:a=!1})=>s.createElement("a",{href:n,target:i,className:e,title:a||"",style:r},t),a=i,c=({children:t,href:e,title:n=!1,Link:r})=>r?s.createElement(r,{href:e,className:o.lD,title:n||""},s.createElement("span",{className:"tw:text-success-content tw:hover:text-success-content"},t)):s.createElement("a",{href:e,className:o.lD,title:n||""},s.createElement("span",{className:"tw:text-success-content tw:hover:text-success-content"},t)),l=({children:t,className:e="tw:bg-base-200 tw:text-base-content",href:n,title:o,icon:r,Link:i})=>(i||(i=a),s.createElement(i,{href:n,className:`tw:px-8 tw:py-10 tw:rounded-lg tw:block ${e}\n tw:hover:bg-secondary/5 tw:shadow-lg tw:bg-base-200\n tw:transition-color tw:duration-300 grow tw:hover:no-underline no-hover-decoration`},s.createElement("h2",{className:"tw:mb-4 tw:text-base-content tw:flex tw:flex-row tw:gap-4 tw:justify-between tw:items-center"},s.createElement("span",{className:"tw:text-base-content"},o),s.createElement("span",{className:"tw:shrink-0 tw:text-base-content"},r)),s.createElement("div",{className:"tw:text-base-content"},t)))},57416:(t,e,n)=>{n.d(e,{A4:()=>o.A,DS:()=>l.D,I3:()=>i.I3,Kk:()=>i.Kk,Ot:()=>c.O,VI:()=>r.V,Vi:()=>a.V,fR:()=>h.f,iR:()=>s.i,iU:()=>c.i,rA:()=>i.rA,zM:()=>o.z});var s=n(80021),o=n(33727),r=n(99005),i=n(27791),a=n(84985),c=n(29203),l=n(19970),h=n(2980)},59427:(t,e,n)=>{n.d(e,{s:()=>a});var s=n(14041),o=n(86560),r=n(56702),i=n(73570);const a=({uuid:t,href:e=!1,label:n="UUID",Link:a=!1})=>(a||(a=r.N_),!1===e?s.createElement("span",{className:"flex flex-row items-center"},s.createElement("span",{className:"daisy-badge daisy-badge-secondary font-mono"},(0,o.c_)(t)),s.createElement(i.T,{content:t,label:n,sup:!0})):s.createElement("span",{className:"flex flex-row items-center"},s.createElement(a,{href:e,title:t},s.createElement("span",{className:"daisy-badge daisy-badge-secondary font-mono"},(0,o.c_)(t))),s.createElement(i.T,{content:t,label:n,sup:!0})))},68024:(t,e,n)=>{n.d(e,{F:()=>r});var s=n(80170);const o={username:!1,control:n(57416).A4.dflt};function r(){const[t,e]=(0,s.A)("fs-account",{defaultValue:o}),[n,r]=(0,s.A)("fs-admin",{defaultValue:o}),[i,a]=(0,s.A)("fs-token",{defaultValue:null}),[c,l]=(0,s.A)("fs-seen-user",{defaultValue:!1}),h=()=>r(o);return{account:t,setAccount:e,token:i,setToken:a,seenUser:c,setSeenUser:l,signOut:()=>{console.log("SIGN OUT"),e(o),a(null)},admin:n,clearAdmin:h,impersonate:n=>{r({token:i,account:t});const s={...n.account,impersonatingAdmin:{id:t.id,username:t.username}};e(s),a(n.token)},stopImpersonating:()=>{e(n.account),a(n.token),h()},control:t?.control||2}}},73570:(t,e,n)=>{n.d(e,{K:()=>c,T:()=>a});var s=n(14041),o=n(86560),r=n(95069),i=n(1199);const a=({children:t,content:e,label:n=!1,sup:a=!1,btnClasses:c="tw:daisy-btn tw:daisy-btn-ghost tw:hover:border-transparent w:hover:border-transparent tw:hover:shadow-none",onCopy:l=!1})=>
1{const[h,p]=(0,s.useState)(!1),{setLoadingStatus:d}=(0,s.useContext)(i.q),u=a?"tw:w-4 tw:h-4 tw:-mt-4 tw:-ml-1":"tw:w-5 tw:h-5";return s.createElement("button",{className:(h?"tw:text-success ":"")+c+" tw:w-full tw:lg:w-auto tw:group tw:flex tw:flex-row tw:justify-between",onClick:()=>((t,e,n,s,r=!1)=>{(0,o.lW)(t),e(!0),n([!0,s?`${s} copied to clipboard`:"Copied to clipboard",!0,!0]),setTimeout((()=>e(!1)),1e3),"function"==typeof r&&r(t,s)})(e,p,d,n,l)},a?t:null,h?s.createElement(r.aV,{className:`${u} tw:text-success-content tw:bg-success tw:rounded-full tw:p-1`,stroke:4}):s.createElement(r.Td,{className:`${u} tw:text-inherit tw:group-hover:text-secondary`}),a?null:t)},c=({btnProps:t={},children:e=[],className:n="",color:o="primary",href:r=!1,onClick:i=!1,title:a=""})=>{const c={className:`tw:daisy-btn-${o} hover:tw:text-${o}-content ${n}`,title:a,...t};return i?c.onClick=i:r&&(c.href=r),i?s.createElement("button",c,s.createElement("div",{className:`tw:text-${o}-content ${l}`},e)):s.createElement("a",c,s.createElement("div",{className:`tw:text-${o}-content ${l}`},e))}
1,l="tw:flex tw:flex-row tw:gap-2 tw:lg:gap-6 tw:items-center tw:grow tw:justify-between tw:w-full tw:md:w-auto tw:daisy-btn tw:hover:no-underline tw:capitalize"},78688:(t,e,n)=>{n.d(e,{Bv:()=>h,Wc:()=>d});var s=n(89575),o=n(14041),r=n(68024),i=n(1199),a=n(50182),c=n(95069),l=n(90512);const h=t=>o.createElement(a.i,null,o.createElement(i.V,null,o.createElement(p,(0,s.A)({},t,{Layout:!1})))),p=({Layout:t=l.PE,children:e=[],crumbs:n=[],description:s="Free Bespoke Sewing Patterns",title:r="FreeSewing"})=>{const{modalContent:c}=(0,o.useContext)(a.V),{LoadingStatus:h}=(0,o.useContext)(i.q);return o.createElement("div",{className:"tailwind-container"},o.createElement(h,null),t?o.createElement(t,{title:r,description:s,crumbs:n},e):e,"function"==typeof c?c():c)},d=t=>{const{id:e,Default:n}=t,s=m[e]?m[e]:n;return o.createElement(s,t)},u=({label:t,Icon:e,href:n,Link:s})=>o.createElement(s,{className:"tw:daisy-btn tw:daisy-btn-ghost tw:hover:no-underline tw:hover:text-base-content custom-navbar-item no-hover-decoration",href:n},o.createElement("div",{className:"tw:flex tw:flex-row tw:gap-2 tw:items-center"},o.createElement(e,{className:"tw:w-6 tw:h-6 tw:text-base-content"}),o.createElement("span",{className:"tw:text-lg tw:text-base-content"},t))),m={account:({Link:t})=>{const[e,n]=(0,o.useState)(!1),{account:s}=(0,r.F)();(0,o.useEffect)((()=>{s?.username&&n(!0)}),[s]);const i=e&&s.username?{Link:t,label:s.username,Icon:c.ny,href:"/account/"}:{Link:t,label:"Sign In",Icon:c.XA,href:"/signin/"};return o.createElement(u,i)},designs:t=>o.createElement(u,{label:"Designs",href:"/designs/",Icon:c.Uk,Link:t.Link}),docs:t=>o.createElement(u,{label:"Docs",href:"/docs/",Icon:c.Vf,Link:t.Link}),showcase:t=>o.createElement(u,{label:"Showcase",href:"/showcase/",Icon:c.jp,Link:t.Link}),blog:t=>o.createElement(u,{label:"Blog",href:"/blog/",Icon:c.wi,Link:t.Link}),forum:t=>o.createElement(u,{label:"Forum",href:"https://forum.freesewing.eu/",Icon:c.oy,Link:t.Link}),support:t=>o.createElement(u,{label:"Support",href:"/support/",Icon:c.NT,Link:t.Link})}},80021:(t,e,n)=>{n.d(e,{i:()=>s});const s={account:"edd96e8b19d1be5946c5f7983365bda4",url:"https://imagedelivery.net/ouSuR9yY1bHt-fuAokSA5Q/",variants:["public","sq100","sq200","sq500","w200","w500","w1000","w2000"],dflt:"https://imagedelivery.net/ouSuR9yY1bHt-fuAokSA5Q/365cc64e-1502-4d2b-60e0-cc8beee73f00/public"}},80170:(t,e,n)=>{n.d(e,{A:()=>l});var s=n(14041);const o=new Map;const r=new Set;function i(t){for(const e of[...r])e(t)}function a(t){return"undefined"===t?void 0:JSON.parse(t)}function c(t){try{return t()}catch{}}const l=function(t,e){const n=e?.serializer,[l]=(0,s.useState)(e?.defaultValue),[h]=(0,s.useState)(e?.defaultServerValue);return function(t,e,n,l=!0,h=a,p=JSON.stringify){const d=(0,s.useRef)({string:null,parsed:void 0}),u=(0,s.useSyncExternalStore)((0,s.useCallback)((e=>{const n=n=>{t===n&&e()};return r.add(n),()=>{r.delete(n)}}),[t]),(()=>{const n=c((()=>localStorage.getItem(t)))??null;if(o.has(t))d.current.parsed=o.get(t);else if(n!==d.current.string){let t;try{t=null===n?e:h(n)}catch{t=e}d.current.parsed=t}return d.current.string=n,void 0!==e&&null===n&&c((()=>{const n=p(e);localStorage.setItem(t,n),d.current={string:n,parsed:e}})),d.current.parsed}),(()=>n??e)),m=(0,s.useCallback)((e=>{const n=e instanceof Function?e(d.current.parsed):e;try{localStorage.setItem(t,p(n)),o.delete(t)}catch{o.set(t,n)}i(t)}),[t,p]),f=(0,s.useCallback)((()=>{c((()=>localStorage.removeItem(t))),o.delete(t),i(t)}),[t]);return(0,s.useEffect)((()=>{if(!l)return;const e=e=>{e.key===t&&e.storageArea===c((()=>localStorage))&&i(t)};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)}),[t,l]),(0,s.useMemo)((()=>[u,m,{isPersistent:u===e||!o.has(t),removeItem:f}]),[t,m,u,e,f])}(t,l,h,e?.storageSync,n?.parse,n?.stringify)}},81637:(t,e,n)=>{n.d(e,{o:()=>c,t:()=>a});var s=n(14041),o=n(50182),r=n(48831),i=n(95069);const a=({tabs:t="",active:e=0,children:n,withModal:a=!1})=>{const{setModal:c}=(0,s.useContext)(o.V),[l,h]=(0,s.useState)(e),p=Array.isArray(t)?t:t.split(",").map((t=>t.trim()));if(!p)return null;const d=n.map(((t,e)=>s.cloneElement(t,{activeTab:l,tabId:e,key:e})));return s.createElement("div",{className:"tw:border tw:border-base-300 tw:rounded-lg tw:pt-2"},s.createElement("div",{className:"tw:daisy-tabs tw:daisy-tabs-border",role:"tablist"},p.map(((t,e)=>{const n=`tw:text-lg tw:font-bold tw:capitalize tw:daisy-tab tw:h-auto tw:grow tw:py-1 ${l===e?"tw:daisy-tab-active":""} tw:border-b-2 tw:border-solid tw:border-x-0 tw:border-t-0 tw:bg-transparent`;return a&&l===e?s.createElement("button",{key:e,role:"tab",className:n,onClick:()=>c(s.createElement(r.F,{flex:"col",justify:"top tw:lg:justify-center",slideFrom:"r
1ight",fullWidth:!0},d))},s.createElement("span",{className:"tw:pr-2"},t),s.createElement(i.Vs,{className:"tw:w-6 tw:h-6 hover:tw:tw:text-secondary"})):s.createElement("button",{key:e,className:n,onClick:()=>h(e)},t)}))),s.createElement("div",{className:"tw:p-4 tw:pb-2"},d))},c=({children:t,tabId:e,activeTab:n})=>n===e?t:null},84985:(t,e,n)=>{n.d(e,{V:()=>s});const s=["basting","biasBinding","blockDevelopment","boning","buttons","curved seams","darts","elastic","gathering","grommets","handSewing","interfacing","knitBinding","lining","pleating","pockets","precision","ribbing","serging","sleeves","topstitching","weltPockets","zipper"]},85627:(t,e,n)=>{n.d(e,{y:()=>o});var s=n(14041);const o=({className:t="tw:h-6 tw:w-6"})=>s.createElement("svg",{className:`tw:animate-spin ${t}`,xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},s.createElement("circle",{className:"tw:opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),s.createElement("path",{className:"tw:opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"}))},86354:(t,e,n)=>{n.d(e,{F:()=>a});n(14041);var s=n(16840),o=n(81637),r=(n(95069),n(73570),n(34519)),i=n(31085);const a=({docs:t,example:e})=>{if(!t)return(0,i.jsx)(r.yV,{children:"No docs passed in"});const n=e||null;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("p",{children:t.desc}),(0,i.jsxs)(o.t,{tabs:"Import, Props, Example, Source",children:[(0,i.jsxs)(o.o,{children:[(0,i.jsxs)("p",{children:["You can import the ",(0,i.jsx)("code",{children:t.name})," component from the ",(0,i.jsx)("b",{children:t.family})," ","component family in the ",(0,i.jsx)("code",{children:"@freesewing/react"})," package:"]}),(0,i.jsx)(s.f,{language:"js",children:t.importAs})]}),(0,i.jsxs)(o.o,{children:[t.params?(0,i.jsxs)("p",{children:[" ","The ",(0,i.jsx)("code",{children:t.name})," component takes the following props:"]}):(0,i.jsx)(r.yV,{children:"This component does not take any props"}),t.params?(0,i.jsx)(c,{docs:t}):null]}),(0,i.jsx)(o.o,{children:(0,i.jsx)(n,{})}),(0,i.jsx)(o.o,{children:(0,i.jsxs)("p",{children:["The ",(0,i.jsx)("code",{children:t.name})," component is defined"," ",(0,i.jsxs)("a",{href:`https://codeberg.org/freesewing/freesewing/src/branch/develop/${t.file}#L${t.line}`,children:["on"," ",(0,i.jsxs)("b",{children:["line"," ",t.line]})," ","in ",(0,i.jsx)("b",{children:t.file})]}),"."]})})]})]})},c=({docs:t})=>(0,i.jsxs)("table",{children:[(0,i.jsx)("thead",{children:(0,i.jsxs)("tr",{children:[(0,i.jsx)("th",{children:"Name"}),(0,i.jsx)("th",{children:"Type"}),(0,i.jsx)("th",{children:"Description"}),(0,i.jsx)("th",{children:"Optional"}),(0,i.jsx)("th",{children:"Default Value"})]})}),(0,i.jsx)("tbody",{children:(t.params||[]).map(((t,e)=>(0,i.jsxs)("tr",{children:[(0,i.jsx)("td",{children:t.name}),(0,i.jsx)("td",{children:t.type.names}),(0,i.jsx)("td",{children:t.description}),(0,i.jsx)("td",{children:t.optional?"yes":"no"}),(0,i.jsx)("td",{children:(0,i.jsx)("code",{children:(0,i.jsx)(l,{value:t.defaultvalue})})})]},e)))})]}),l=({value:t})=>!0===t?"true":!1===t?"false":null===t?"null":void 0===t?"undefined":t},86560:(t,e,n)=>{n.d(e,{ZH:()=>w,o8:()=>x,qk:()=>_,lW:()=>Z,cA:()=>k,Ky:()=>M,p3:()=>b,pc:()=>E,m2:()=>$,ZV:()=>L,Ee:()=>C,Jt:()=>p,ov:()=>N,z4:()=>A,f_:()=>f,Ci:()=>g,lD:()=>y,R8:()=>O,_p:()=>R,G0:()=>j,oo:()=>J,z2:()=>z,My:()=>m,XK:()=>I,RT:()=>T,lg:()=>H,LI:()=>F,hZ:()=>d,XV:()=>D,c_:()=>U,Z6:()=>q,fF:()=>B,Ip:()=>v,DT:()=>W,Pb:()=>G});var s=n(34172),o=n(57416),r=n(46123),i=n(41263),a=n(73450),c=n(56622);n(69182);const l=["Unfolding ideas...","Teaching hamsters to run faster...","Convincing pixels to get in line...","Warming up the flux capacitor...","Untangling digital spaghetti...","Counting backwards from infinity...","Generating witty loading messages...","Brewing digital coffee...","Herding cats into quantum boxes...","Downloading more RAM...","Dividing by zero...","Spinning up the hamster wheel...","Convert
1ing caffeine to code...","Bending the space-time continuum...","Charging laser batteries...","Summoning the data spirits...","Searching for the lost semicolon...","Consulting the digital rolodex...","Calibrating the flux capacitor...","Collecting magic internet points...","Solving P vs NP...","Compressing time and space...","Entering the matrix...","Upgrading to Web 4.0...","Debugging the debugger..."];var h=n(52665);const p=r,d=i,u=a,m=c,f="tw:flex tw:flex-row tw:items-center tw:justify-between tw:gap-4 tw:w-full",g="tw:md:flex tw:md:flex-row tw:md:items-center tw:md:justify-between tw:md:gap-4 tw:w-full",y="tw:text-secondary tw:hover:underline tw:hover:cursor-pointer";function w(t){return"string"==typeof t?t.charAt(0).toUpperCase()+t.slice(1):""}function x(t){return JSON.parse(JSON.stringify(t))}function b(t){return String(t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function v({ihash:t=!1,variant:e="public"}){return o.iR.variants.includes(e)||(e="sq100"),_(t?{id:`uid-${t}`,variant:e}:{id:"default-avatar",variant:e})}function _({id:t="default-avatar",variant:e="public"}){return t&&"default-avatar"!==t?(o.iR.variants.includes(e)||(e="sq100"),`${o.iR.url}${t}/${e}`):o.iR.dflt}function k(t){return void 0!==t?.pct?"pct":void 0!==t?.bool?"bool":void 0!==t?.count?"count":void 0!==t?.deg?"deg":void 0!==t?.list?"list":void 0!==t?.mm?"mm":"constant"}function M(t=!1,e=!1){if(!t)return!1;const n=e?/^-?[0-9]*(\s?[0-9]+\/|[.])?[0-9]+$/:/^-?[0-9]*[.]?[0-9]+$/;return!!(t=t.toString().trim().replace(",",".")).match(n)&&(e&&(t=S(t)),!isNaN(t)&&Number(t))}const E=(t,e="html")=>{let n="",s="",o="";t<0&&(t*=-1,n="-"),Math.abs(t)<1?o=t:(s=Math.floor(t),o=t-s);let r=Math.round(128*o);if(0==r)return P(n,s||r,!1,!1,e);for(let i=1;i<7;i++){const t=Math.pow(2,7-i);if(r%t==0)return P(n,s,r/t,Math.pow(2,i),e)}return n+Math.round(100*t)/100+("html"===e||"notags"===e?'"':"")};function P(t,e,n=!1,s=!1,o="html"){return"html"===o?n?`${t}${e} <sup>${n}</sup>/<sub>${s}</sub>"`:`${t}${e}"`:"notags"===o?n?`${t}${e} ${n}/${s}"`:`${t}${e}"`:n?`${t}${e} ${n}/${s}`:`${t}${e}`}function $(t,e,n="html"){if(t=V(t),"imperial"===e||!0===e){if(0==t)return P("",0,!1,!1,n);return E(t/25.4,n)}return"html"===n||"notags"===n?V(t/10)+"cm":V(t/10)}const L=(t,e="")=>{if(null==t)return t;if(void 0!==t.value&&(t=t.value),t<1)return t;if(t){const n=["","K","M","B"],s=Math.min(parseInt(Math.floor(Math.log(t)/Math.log(1e3)).toString(),10),n.length-1);return`${(t/1e3**s).toFixed(s?1:0)}${n[s]}${e}`}return"0"};function C(t){return Math.round(1e3*t)/10+"%"}function S(t){if(!isNaN(t))return t;let e=0,n=String(t).split(" ");if(n.length>2)return Number.NaN;if(2===n.length){const t=Number(n.shift());if(isNaN(t))return Number.NaN;e+=t}let s=n[0].trim().split("/");if(2!==s.length||""===s[1])return Number.NaN;let o=Number(s[0]),r=Number(s[1]);return isNaN(o)||isNaN(r)?NaN:e+o/r}function N(t="id"){if("undefined"!=typeof window)return new URLSearchParams(window.location.search).get(t)}function A(t,e={}){t=function(t){return t?.patternConfig?t:{patternConfig:{measurements:t}}}(t);const n=[];for(const s of t.patternConfig?.measurements||[])void 0===e[s]&&n.push(s);return[0===n.length,n]}function O(t,e="metric"){if("number"==typeof t)return t*("imperial"===e?25.4:10);if(String(t).endsWith("."))return!1;if("metric"===e)return t=Number(t),!isNaN(t)&&10*t;{const e=S(t);return!isNaN(e)&&25.4*e}}function R(t,e="metric"){return F(t/("imperial"===e?25.4:10),4)}const j=(t={},e,n="unset")=>{if("unset"===n)if(Array.isArray(e)&&Array.isArray(e[0]))for(const[s,o="unset"]of e)"unset"===o?u(t,s):d(t,s,o);else u(t,e);else d(t,e,n);return t};function I(t){let e=new h.dd;for(const n of t.ops)"move"===n.type&&(e=e.move(new h.bR(n.to.x,n.to.y))),"line"===n.type&&(e=e.line(new h.bR(n.to.x,n.to.y))),"curve"===n.type&&(e=e.curve(new h.bR(n.cp1.x,n.cp1.y),new h.bR(n.cp2.x,n.cp2.y),new h.bR(n.to.x,n.to.y))),"close"===n.type&&(e=e.close());return e.length()}const T=(t={},e=!1,n="draft")=>{const s=x(t),o=e?{...s.settings?.measurements||{}}:{},r={...s.settings||{}};r.measurements=o;const i={design:s.design,settings:r,view:n};return t.id&&(i.pid=t.id),`/editor/#s=${encodeURIComponent(JSON.stringify(i))}`},z=t=>`${t}`.length>0;function H(){return l[Math.floor(Math.random()*l.length)]}function F(t,e=1){return Math.round(t*Math.pow(10,e))/Math.pow(10,e)}function V(t,e){return"imperial"===e||!0===e?Math.round(1e6*t)/1e6:Math.round(10*t)/10}function D(t=!1,e=!0){const n={year:"numeric",month:"short",day:"numeric"};e&&(n.hour="2-digit",n.minute="2-digit",n.hour12=!1);return(t?new Date(t):new Date).toLocaleDateString("en",n)}const U=t=>t.slice(0,5);
1function B(t,e=!0){const n=new Date-new Date(t),s=Math.floor(n/1e3),o=Math.floor(s/60),r=Math.floor(o/60),i=Math.floor(r/24),a=Math.floor(i/30),c=Math.floor(i/365),l=" ago";return s<1?"Now":1===s?`${e?"1s":"1 second"}${l}`:60===s?`${e?"1m":"1 minute"}${l}`:s<91?`${s}${e?"s":" seconds"}${l}`:60===o?`${e?"1h":"1 hour"}${l}`:o<120?`${o}${e?"m":" minutes"}${l}`:24===r?`${e?"1d":"1 day"}${l}`:r<48?`${r}${e?"h":" hours"}${l}`:i<61?`${i}${e?"d":" days"}${l}`:a<25?`${a}${e?"M":" months"}${l}`:`${c}${e?"Y":" years"}${l}`}function W(t){return/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(t)}function G(t){const e=t.split("@").pop().split(".").pop().toLowerCase();return-1!==s.indexOf(e)||e}function Z(t){navigator?.clipboard?navigator.clipboard.writeText(t).catch((e=>{console.error("Failed to use the clipboard API to copy text to clipboard:",e),Y(t)})):Y(t)}function Y(t){const e=document.createElement("textarea");e.value=t,e.style.position="fixed",document.body.appendChild(e),e.select(),document.execCommand("copy"),document.body.removeChild(e)}function J(t,e=!1){window&&(window.location.href=e?`${window.location.origin}${t}`:t)}const q=(t,e=!1)=>{if(!e)return t;const n=t.split(":");return n[0]=e,n.join(":")}},90512:(t,e,n)=>{n.d(e,{I_:()=>d,PE:()=>i,YS:()=>a,bi:()=>c,jR:()=>p,yw:()=>l,zz:()=>h});var s=n(14041),o=n(97230),r=n(56702);const i=({children:t=[],crumbs:e=[],Link:n=!1,title:i})=>(n||(n=r.N_),s.createElement(a,null,s.createElement("div",{className:"tw:max-w-xl tw:w-full tw:mx-auto"},s.createElement(o.B,{crumbs:e,title:i,Link:n}),s.createElement("h1",{className:"tw:break-words"},i),s.createElement("div",{className:"tw:xl:pl-4"},t)))),a=({children:t})=>s.createElement("div",{className:"tw:flex tw:flex-row tw:items-start tw:w-full tw:justify-between tw:2xl:px-36 tw:xl:px-12 tw:px-4 tw:gap-0 tw:lg:gap-4 tw:xl:gap-8 3xl:tw:gap-12"},t),c=({children:t=[]})=>s.createElement("div",{className:"tw:max-w-96 tw:w-1/4 tw:hidden tw:lg:block tw:shrink-0 tw:my-8 tw:sticky tw:top-4 tw:max-h-screen tw:overflow-scroll"},t),l=({children:t=[]})=>s.createElement("div",{className:"tw:max-w-96 tw:w-1/4 tw:hidden tw:xl:block tw:my-8 tw:sticky tw:top-2"},t),h=({children:t=[],wide:e=!1})=>s.createElement("div",{className:`tw:grow tw:w-full tw:m-auto tw:max-w-${e?"full":"prose"} tw:my-8`},t),p=({children:t=[]})=>s.createElement("div",{className:"tw:grow tw:w-full tw:m-auto tw:my-8 tw:grow"},t),d=({children:t})=>s.createElement(a,null,s.createElement("div",{className:"tw:max-w-xl tw:w-full tw:mx-auto"},s.createElement("div",null,t)))},95069:(t,e,n)=>{n.d(e,{AD:()=>oe,Ab:()=>St,BK:()=>Ut,C3:()=>q,CR:()=>it,Ct:()=>$,DZ:()=>S,Ex:()=>dt,Ey:()=>V,FN:()=>B,G:()=>Et,GP:()=>z,GQ:()=>y,H2:()=>ut,HD:()=>M,H_:()=>Nt,Hd:()=>Xt,Hk:()=>Z,IJ:()=>I,JM:()=>Kt,Je:()=>W,LP:()=>Ot,Lo:()=>re,N0:()=>pt,NA:()=>$t,NR:()=>Y,NT:()=>X,Nl:()=>Dt,O_:()=>se,PX:()=>ne,Pd:()=>Rt,Q8:()=>xt,RY:()=>tt,Rq:()=>wt,Ru:()=>lt,SH:()=>K,TP:()=>G,Td:()=>P,Ty:()=>d,US:()=>v,Uk:()=>C,V5:()=>Wt,Vf:()=>N,Vs:()=>et,WI:()=>Tt,XA:()=>rt,Xy:()=>Yt,YG:()=>F,Yp:()=>vt,Z3:()=>p,ZB:()=>ht,Ze:()=>zt,Zm:()=>te,aP:()=>Lt,aV:()=>ft,aZ:()=>j,aj:()=>x,bo:()=>Zt,c1:()=>_t,cF:()=>m,cG:()=>l,cp:()=>f,cu:()=>h,cw:()=>Bt,ej:()=>Jt,g6:()=>Mt,hM:()=>kt,hh:()=>a,hl:()=>k,hs:()=>ct,iF:()=>U,iQ:()=>It,id:()=>ee,ik:()=>H,j1:()=>bt,jD:()=>L,jf:()=>Pt,jp:()=>Ft,k5:()=>A,kp:()=>ot,lQ:()=>qt,lm:()=>Ht,lo:()=>_,mE:()=>gt,mS:()=>T,nF:()=>J,ny:()=>Qt,oW:()=>Q,oy:()=>g,p6:()=>Vt,qU:()=>R,qY:()=>st,rG:()=>D,rZ:()=>nt,s3:()=>O,sN:()=>jt,sQ:()=>c,tJ:()=>w,uc:()=>Gt,ve:()=>b,wF:()=>Ct,wi:()=>At,xf:()=>mt,xh:()=>E,z3:()=>yt,zA:()=>at,zB:()=>u});var s=n(89575),o=n(14041),r=n(57416);const i="M19.5 14.25v-2.625a3.375 3.375 0 00-3.375-3.375h-1.5A1.125 1.125 0 0113.5 7.125v-1.5a3.375 3.375 0 00-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 00-9-9z",a=({className:t="tw:w-6 tw:h-6",stroke:e=2,children:n=null,fill:s=!1,fillOpacity:r=1,dasharray:i=null})=>o.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:s?"currentColor":"none",fillOpacity:r,strokeOpacity:r,viewBox:"0 0 24 24",strokeWidth:e,stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeDasharray:i||"",className:t+" icon"},n),c=t=>
1o.createElement(a,t,o.createElement("path",{d:"M5.25 5.653c0-.856.917-1.398 1.667-.986l11.54 6.347a1.125 1.125 0 0 1 0 1.972l-11.54 6.347a1.125 1.125 0 0 1-1.667-.986V5.653Z"})),l=t=>o.createElement(a,t,o.createElement("path",{d:"M 16.004103,4.4394969 V 20.706071 M 3.1922297,4.3530908 H 20.925704 c 1.04693,0 1.889764,0.8428346 1.889764,1.8897638 V 18.889699 c 0,1.04693 -0.842834,1.889764 -1.889764,1.889764 H 3.1922297 c -1.0469291,0 -1.8897638,-0.842834 -1.8897638,-1.889764 V 6.2428546 c 0,-1.0469292 0.8428347,-1.8897638 1.8897638,-1.8897638 z"})),h=t=>o.createElement(a,t,o.createElement("path",{d:"M9.75 3.104v5.714a2.25 2.25 0 01-.659 1.591L5 14.5M9.75 3.104c-.251.023-.501.05-.75.082m.75-.082a24.301 24.301 0 014.5 0m0 0v5.714c0 .597.237 1.17.659 1.591L19.8 15.3M14.25 3.104c.251.023.501.05.75.082M19.8 15.3l-1.57.393A9.065 9.065 0 0112 15a9.065 9.065 0 00-6.23-.693L5 14.5m14.8.8l1.402 1.402c1.232 1.232.65 3.318-1.067 3.611A48.309 48.309 0 0112 21c-2.773 0-5.491-.235-8.135-.687-1.718-.293-2.3-2.379-1.067-3.61L5 14.5"})),p=t=>o.createElement(a,(0,s.A)({},t,{className:`${t.className||"tw:w-6 tw:h-6"} tw:-rotate-45`}),o.createElement("path",{d:"M9 15 3 9m0 0 6-6M3 9h12a6 6 0 0 1 0 12h-3"})),d=({size:t=6})=>o.createElement(mt,{className:`tw:w-${t} tw:h-${t} tw:text-error`,stroke:4}),u=({size:t=6})=>o.createElement(ft,{className:`tw:w-${t} tw:h-${t} tw:text-success`,stroke:4}),m=t=>o.createElement(a,t,o.createElement("path",{d:"M17.593 3.322c1.1.128 1.907 1.077 1.907 2.185V21L12 17.25 4.5 21V5.507c0-1.108.806-2.057 1.907-2.185a48.507 48.507 0 0111.186 0z"})),f=t=>o.createElement(a,t,o.createElement("circle",{cx:"12",cy:"12",r:"8"})),g=t=>o.createElement(a,t,o.createElement("path",{d:"M2.25 12.76c0 1.6 1.123 2.994 2.707 3.227 1.087.16 2.185.283 3.293.369V21l4.076-4.076a1.526 1.526 0 011.037-.443 48.282 48.282 0 005.68-.494c1.584-.233 2.707-1.626 2.707-3.228V6.741c0-1.602-1.
1123-2.995-2.707-3.228A48.394 48.394 0 0012 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018z"})),y=t=>o.createElement(a,t,o.createElement("circle",{cx:"12",cy:"12",r:"10"}),t.label?o.createElement("text",{x:"12",y:"17.5",stroke:"none",fill:"currentColor",textAnchor:"middle"},t.label):null),w=t=>o.createElement(a,t,o.createElement("path",{d:"m 8.233159,2.5000002 c 0,0 0.03684,1.4367676 0.07562,2.1541457 C 8.413989,6.5901608 7.3671071,6.9496995 7.3372662,8.1692173 7.3029172,9.5719723 8.2152,10.315942 8.255388,12.267223 8.290568,13.973294 7.1739465,15.012709 7.1739465,17.259683 9.46861,17.549817 10.668009,19.205086 11.354231,21.5 h 0.109763 0.93923 0.109803 c 0.686181,-2.294914 1.88558,-3.950183 4.180285,-4.240317 0,-2.246974 -1.116622,-3.286389 -1.081483,-4.99246 0.04015,-1.951281 0.952433,-2.6952507 0.918122,-4.0980057 -0.0298,-1.2195178 -1.076723,-1.5790565 -0.971513,-3.5150714 0.0389,-0.7173781 0.07562,-2.1541457 0.07562,-2.1541457 h -0.722313 c 0,1.5276628 -1.146752,3.7763442 -2.978112,3.7763442 -1.831402,0 -2.978154,-2.2486814 -2.978154,-3.7763442 z"})),x=t=>o.createElement(a,t,o.createElement("path",{d:"M 6.2021092,6.7988281 C 5.0433189,10.972649 5.2215488,13.211802 5.2215488,16.798828 h 5.8983122 l 0.143133,-1.21128 c 0.331559,-1.834081 0.655671,-2.543616 1.078829,0.07477 l 0.134587,1.136509 h 5.896176 c 0,-3.587026 0.180363,-5.826179 -0.978425,-9.9999999 z"})),b=t=>o.createElement(a,t,o.createElement("path",{d:"M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 01-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 011.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 00-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 01-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 00-3.375-3.375h-1.5a1.125 1.125 0 01-1.125-1.125v-1.5a3.375 3.375 0 00-3.375-3.375H9.75"})),v=t=>o.createElement(a,t,o.createElement("path",{d:"M6 18L18 6M6 6l12 12"})),_=t=>o.createElement(a,t,o.createElement("path",{d:"M17.25 6.75 22.5 12l-5.25 5.25m-10.5 0L1.5 12l5.25-5.25m7.5-3-4.5 16.5"})),k=t=>o.createElement(a,t,o.createElement("path",{d:"m15 15v4.5m0-4.5h4.5m-15.8-11.3 5.25 5.25m6 0v-4.5m0 4.5h4.5m-15.8 11.3 5.25-5.25h-4.5m4.5 0v4.5m11.3-15.8-5.25 5.25m-6 0h-4.5m4.5 0v-4.5m11.3 15.8-5.25-5.25"})),M=t=>o.createElement(a,t,o.createElement("path",{d:"M2.25 7.125C2.25 6.504 2.754 6 3.375 6h6c.621 0 1.125.504 1.125 1.125v3.75c0 .621-.504 1.125-1.125 1.125h-6a1.125 1.125 0 01-1.125-1.125v-3.75zM14.25 8.625c0-.621.504-1.125 1.125-1.125h5.25c.621 0 1.125.504 1.125 1.125v8.25c0 .621-.504 1.125-1.125 1.125h-5.25a1.125 1.125 0 01-1.125-1.125v-8.25zM3.75 16.125c0-.621.504-1.125 1.125-1.125h5.25c.621 0 1.125.504 1.125 1.125v2.25c0 .621-.504 1.125-1.125 1.125h-5.25a1.125 1.125 0 01-1.125-1.125v-2.25z"})),E=t=>o.createElement(a,t,o.createElement("path",{d:"M12 3v17.25m0 0c-1.472 0-2.882.265-4.185.75M12 20.25c1.472 0 2.882.265 4.185.75M18.75 4.97A48.416 48.416 0 0012 4.5c-2.291 0-4.545.16-6.75.47m13.5 0c1.01.143 2.01.317 3 .52m-3-.52l2.62 10.726c.122.499-.106 1.028-.589 1.202a5.988 5.988 0 01-2.031.352 5.988 5.988 0 01-2.031-.352c-.483-.174-.711-.703-.59-1.202L18.75 4.971zm-16.5.52c.99-.203 1.99-.377 3-.52m0 0l2.62 10.726c.122.499-.106 1.028-.589 1.202a5.989 5.989 0 01-2.031.352 5.989 5.989 0 01-2.031-.352c-.483-.174-.711-.703-.59-1.202L5.25 4.971z"})),P=t=>o.createElement(a,t,o.createElement("path",{d:"M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z"})),$=t=>o.createElement(a,t,o.createElement("path",{d:i}),o.createElement("circle",{cx:"9",cy:"12",r:"1"}),o.createElement("circle",{cx:"14",cy:"12",r:"1"}),o.createElement("path",{d:"M 9 16 C 11 18 12 18 14 16"})),L=t=>o.createElement(a,t,o.createElement("path",{d:"M12 21v-8.25M15.75 21v-8.25M8.25 21v-8.25M3 9l9-6 9 6m-1.5 12V10.332A48.36 48.36 0 0012 9.75c-2.551 0-5.056.2-7.5.582V21M3 21h18M12 6.75h.008v.008H12V6.75z"})),C=t=>o.createElement(a,(0,s.A)({},t,{stroke:0,fill:!0}),o.createElement("path",{d:"m11.975 2.9104c-1.5285 0-2.7845 1.2563-2.7845 2.7848 0 0.7494 0.30048 1.4389 0.78637 1.9394a0.79437 0.79437 0 0 0 0.0084 0.00839c0.38087 0.38087 0.74541 0.62517 0.94538 0.82483 0.19998 0.19966 0.25013 0.2645 0.25013 0.51907v0.65964l-9.1217 5.2665c-0.28478 0.16442-0.83603 0.46612-1.3165 0.9611-0.48047 0.49498-0.92451 1.3399-0.66684 2.2585 0.22026 0.78524 0.7746 1.3486 1.3416 1.5878 0.56697 0.23928 1.0982 0.23415 1.4685 0.23415h18.041c0.37033 0 0.90158 0.0051 1.4686-0.23415 0.56697-0.23928 1.1215-0.80261 1.3418-1.5878 0.25767-0.91859-0.18662-1.7636-0.66709-2.2585-0.48046-0.49498-1.0315-0.79669
1-1.3162-0.9611l-8.9844-5.1873v-0.73889c0-0.70372-0.35623-1.2837-0.71653-1.6435-0.35778-0.3572-0.70316-0.58503-0.93768-0.81789-0.20864-0.21601-0.33607-0.50298-0.33607-0.83033 0-0.67 0.52595-1.1962 1.1959-1.1962 0.67001 0 1.1962 0.5262 1.1962 1.1962a0.79429 0.79429 0 0 0 0.79434 0.79427 0.79429 0.79429 0 0 0 0.79427-0.79427c0-1.5285-1.2563-2.7848-2.7848-2.7848zm-0.06859 8.2927 8.9919 5.1914c0.28947 0.16712 0.69347 0.41336 0.94393 0.67138 0.25046 0.25803 0.31301 0.3714 0.24754 0.60483-0.10289 0.36677-0.19003 0.40213-0.35969 0.47373-0.16967 0.07161-0.47013 0.09952-0.80336 0.09952h-18.041c-0.33323 0-0.6337-0.02792-0.80336-0.09952-0.16967-0.07161-0.25675-0.10696-0.35963-0.47373-0.06548-0.23342-0.00303-0.3468 0.24748-0.60483 0.25046-0.25803 0.65471-0.50426 0.94418-0.67138z"})),S=t=>o.createElement(a,t,o.createElement("path",{d:"M3.98 8.223A10.477 10.477 0 0 0 1.934 12C3.226 16.338 7.244 19.5 12 19.5c.993 0 1.953-.138 2.863-.395M6.228 6.228A10.451 10.451 0 0 1 12 4.5c4.756 0 8.773 3.162 10.065 7.498a10.522 10.522 0 0 1-4.293 5.774M6.228 6.228 3 3m3.228 3.228 3.65 3.65m7.894 7.894L21 21m-3.228-3.228-3.65-3.65m0 0a3 3 0 1 0-4.243-4.243m4.242 4.242L9.88 9.88"})),N=t=>o.createElement(a,t,o.createElement("path",{d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})),A=t=>o.createElement(a,t,o.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:t.stroke||2,d:"M19 9l-7 7-7-7"})),O=t=>o.createElement(a,t,o.createElement("path",{d:"M12 9.75v6.75m0 0l-3-3m3 3l3-3m-8.25 6a4.5 4.5 0 01-1.41-8.775 5.25 5.25 0 0110.233-2.33 3 3 0 013.758 3.848A3.752 3.752 0 0118 19.5H6.75z"})),R=t=>o.createElement(a,t,o.createElement("path",{d:"M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z"})),j=t=>o.createElement(a,t,o.createElement("path",{d:"M21.75 6.75v10.5a2.25 2.25 0 01-2.25 2.25h-15a2.25 2.25 0 01-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0019.5 4.5h-15a2.25 2.25 0 00-2.25 2.25m19.5 0v.243a2.25 2.25 0 01-1.07 1.916l-7.5 4.615a2.25 2.25 0 01-2.36 0L3.32 8.91a2.25 2.25 0 01-1.07-1.916V6.75"})),I=t=>o.createElement(a,t,o.createElement("path",{d:"M12 9v3.75m9-.75a9 9 0 11-18 0 9 9 0 0118 0zm-9 3.75h.008v.008H12v-.008z"})),T=t=>o.createElement(a,t,o.createElement("path",{d:"M3.75 3.75v4.5m0-4.5h4.5m-4.5 0L9 9M3.75 20.25v-4.5m0 4.5h4.5m-4.5 0L9 15M2
10.25 3.75h-4.5m4.5 0v4.5m0-4.5L15 9m5.25 11.25h-4.5m4.5 0v-4.5m0 4.5L15 15"})),z=t=>o.createElement(a,t,o.createElement("path",{d:"M12 10v6m0 0l-3-3m3 3l3-3m2 8H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})),H=({size:t=6})=>o.createElement(mt,{className:`tw:w-${t} tw:h-${t} tw:text-secondary-content`,stroke:4}),F=t=>o.createElement(a,t,o.createElement("path",{d:"M3 4a1 1 0 011-1h16a1 1 0 011 1v2.586a1 1 0 01-.293.707l-6.414 6.414a1 1 0 00-.293.707V17l-4 4v-6.586a1 1 0 00-.293-.707L3.293 7.293A1 1 0 013 6.586V4z"})),V=t=>o.createElement(a,t,o.createElement("path",{d:"M7.864 4.243A7.5 7.5 0 0119.5 10.5c0 2.92-.556 5.709-1.568 8.268M5.742 6.364A7.465 7.465 0 004.5 10.5a7.464 7.464 0 01-1.15 3.993m1.989 3.559A11.209 11.209 0 008.25 10.5a3.75 3.75 0 117.5 0c0 .527-.021 1.049-.064 1.565M12 10.5a14.94 14.94 0 01-3.6 9.75m6.633-4.596a18.666 18.666 0 01-2.485 5.33"})),D=t=>o.createElement(a,t,o.createElement("path",{d:"M12 9v3.75m9-.75a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9 3.75h.008v.008H12v-.008Z"})),U=t=>o.createElement(a,t,o.createElement("path",{d:"M3 3v1.5M3 21v-6m0 0l2.77-.693a9 9 0 016.208.682l.108.054a9 9 0 006.086.71l3.114-.732a48.524 48.524 0 01-.005-10.499l-3.11.732a9 9 0 01-6.085-.711l-.108-.054a9 9 0 00-6.208-.682L3 4.5M3 15V4.5"})),B=t=>o.createElement(a,t,o.createElement("path",{d:"M7.5 21 3 16.5m0 0L7.5 12M3 16.5h13.5m0-13.5L21 7.5m0 0L16.5 12M21 7.5H7.5"})),W=t=>o.createElement(a,(0,s.A)({},t,{stroke:0,fill:!0}),o.createElement("path",{d:r.VI})),G=t=>o.createElement(a,t,o.createElement("path",{d:"M 4.9580501,20.694732 A 9.9588146,9.9588156 45 0 1 4.9523103,6.6165865 9.9588146,9.9588156 45 0 1 19.030446,6.5993628 9.9588146,9.9588156 45 0 1 19.059151,20.67748 Z"}),o.createElement("path",{d:"m 13.346899,14.905658 c 0.185287,0.691503 -0.22474,1.402361 -0.916092,1.588212 -0.691356,0.185836 -1.402539,-0.223628 -1.588938,-0.914833 -0.186401,-0.691204 0.222481,-1.402721 0.913533,-1.589686 l 4.660195,-6.2056598 z"})),Z=t=>o.createElement(a,(0,s.A)({},t,{stroke:0,fill:!0}),o.createElement("path",{d:"M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"})),Y=t=>o.createElement(a,(0,s.A)({},t,{fill:!0}),o.createElement("path",{d:"M 12.25009,0 C 7.5567085,0 3.5033589,2.69334 1.530043,6.613315 0.71674427,8.240005 0.25,10.06676 0.25,12.00009 c 0,1.93333 0.46674427,3.759905 1.280043,5.386595 C 3.5033589,21.30666 7.5567085,24 12.25009,24 c 3.239959,0 5.959944,-1.066635 7.94668,-2.906575 2.266629,-2.093365 3.573349,-5.173415 3.573349,-8.826735 0,-0.98666 -0.08023,-1.70661 -0.253496,-2.453265 l -11.266533,0 0,4.45322 6.613137,0 c -0.133283,1.106705 -0.853233,2.77333 -2.453266,3.89327 -1.013315,0.706675 -2.373243,1.199975 -4.159871,1.199975 -3.173318,0 -5.8666835,-2.09327 -6.826777,-4.986605 -0.2533286,-0.746655 -0.399991,-1.54657 -0.399991,-2.373195 0,-0.82672 0.1467055,-1.62672 0.386706,-2.373375 C 6.3834495,6.73338 9.076772,4.63993 12.25009,4.63993 c 2.253301,0 3.773228,0.973465 4.639932,1.786855 L 20.27666,3.12004 C 18.196718,1.186705 15.490049,0 12.25009,0 Z"})),J=t=>o.createElement(a,t,o.createElement("path",{d:"M20 7l-8-4-8 4m16 0l-8 4m8-4v10l-8 4m0-10L4 7m8 4v10M4 7v10l8 4"})),q=t=>o.createElement(a,t,o.createElement("path",{d:"M4.318 6.318a4.5 4.5 0 000 6.364L12 20.364l7.682-7.682a4.5 4.5 0 00-6.364-6.364L12 7.636l-1.318-1.318a4.5 4.5 0 00-6.364 0z"})),X=t=>o.createElement(a,t,o.createElement("path",{d:"M9.879 7.519c1.171-1.025 3.071-1.025 4.242 0 1.172 1.025 1.172 2.687 0 3.712-.203.179-.43.326-.67.442-.745.361-1.45.999-1.45 1.827v.75M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9 5.25h.008v.008H12v-.008z"})),K=t=>o.createElement(a,t,o.createElement("path",{d:"M10.5 6a7.5 7.5 0 107.5 7.5h-7.5V6z"}),o.createElement("path",{d:"M13.5 10.5H21A7.5 7.5 0 0013.5 3v7.5z"})),Q=t=>o.createElement(a,(0,s.A)({},t,{stroke:0,fill:!0}),o.createElement("path",{d:"M12 0C8.74 0 8.333.015 7.053.072 5.775.132 4.905.333 4.14.63c-.789.306-1.459.717-2.126 1.384S.935 3.35.63 4.14C.333 4.905.131 5.775.072 7.053.012 8.333 0 8.74 0 12s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558C8.333 23.988 8.74 24
112 24s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126C21.319 1.347 20.651.935 19.86.63c-.765-.297-1.636-.499-2.913-.558C15.667.012 15.26 0 12 0zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06l.045.03zm0 3.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44 0-.794.646-1.439 1.44-1.439.793-.001 1.44.645 1.44 1.439z"})),tt=t=>o.createElement(a,t,o.createElement("path",{d:"M15.75 5.25a3 3 0 013 3m3 0a6 6 0 01-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1121.75 8.25z"})),et=t=>o.createElement(a,t,o.createElement("path",{d:"M 3,17.033898 V 7.2838983 c 0,-1.242641 1.007359,-2.25 2.25,-2.25 h 13.5 c 1.242641,0 2.25,1.007359 2.25,2.25 v 9.7499997 m -18,0 c 0,1.242641 1.007359,2.25 2.25,2.25 h 13.5 c 1.242641,0 2.25,-1.007359 2.25,-2.25"})),nt=t=>o.createElement(a,t,o.createElement("path",{d:"M15 19l-7-7 7-7"})),st=t=>o.createElement(a,t,o.createElement("path",{d:"M13.19 8.688a4.5 4.5 0 011.242 7.244l-4.5 4.5a4.5 4.5 0 01-6.364-6.364l1.757-1.757m13.35-.622l1.757-1.757a4.5 4.5 0 00-6.364-6.364l-4.5 4.5a4.5 4.5 0 001.242 7.244"})),ot=t=>o.createElement(a,t,o.createElement("path",{d:"M8.25 6.75h12M8.25 12h12m-12 5.25h12M3.75 6.75h.007v.008H3.75V6.75Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0ZM3.75 12h.007v.008H3.75V12Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm-.375 5.25h.007v.008H3.75v-.008Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z"})),rt=t=>o.createElement(a,t,o.createElement("path",{d:"M16.5 10.5V6.75a4.5 4.5 0 10-9 0v3.75m-.75 11.25h10.5a2.25 2.25 0 002.25-2.25v-6.75a2.25 2.25 0 00-2.25-2.25H6.75a2.25 2.25 0 00-2.25 2.25v6.75a2.25 2.25 0 002.25 2.25z"})),it=t=>o.createElement(a,t,o.createElement("path",{d:"m 2.4889452,14.488945 h 7.0221096 v 7.02211 H 2.4889452 Z M 14.488945,2.4889452 h 7.02211 v 7.0221096 h -7.02211 z m -11.9999998,0 H 9.5110548 V 9.5110548 H 2.4889452 Z M 14.488945,14.488945 h 7.02211 v 7.02211 h -7.02211 z"})),at=t=>o.createElement(a,(0,s.A)({},t,{fill:!0,stroke:0}),o.createElement("path",{d:"m 11.217423,0.1875 c -2.8267978,0.0231106 -5.545964,0.32921539 -7.1306105,1.056962 0,0 -3.14282962,1.4058166 -3.14282962,6.2023445 0,1.0983506 -0.021349,2.4116171 0.013437,3.8043315 0.11412502,4.690743 0.85993502,9.313695 5.19692442,10.461603 1.9996899,0.529281 3.7166529,0.640169 5.0993757,0.564166 2.507534,-0.139021 3.915187,-0.894849 3.915187,-0.894849 l -0.08272,-1.819364 c 0,0 -1.79194,0.564966 -3.804377,0.496111 -1.9938518,-0.06838 -4.0987697,-0.214969 -4.4212502,-2.662908 -0.029782,-0.215025 -0.044673,-0.445024 -0.044673,-0.686494 0,0 1.9573364,0.47844 4.4378282,0.592088 1.516743,0.06957 2.939062,-0.08886 4.383732,-0.261231 2.770451,-0.330816 5.182722,-2.037815 5.485905,-3.597546 0.477704,-2.456993 0.438356,-5.9959075 0.438356,-5.9959075 0,-4.7965279 -3.142655,-6.2023445 -3.142655,-6.2023445 C 16.83453,0.51671539 14.113674,0.21061063 11.286876,0.1875 Z M 8.0182292,3.9352913 c 1.177465,0 2.0690118,0.4525587 2.6585778,1.3578046 l 0.573249,0.9608111 0.573247,-0.9608111 c 0.589448,-0.9052459 1.480995,-1.3578046 2.65858,-1.3578046 1.017594,0 1.837518,0.3577205 2.463657,1.0555661 0.606959,0.6978459 0.909169,1.6411822 0.909169,2.8281631 V 13.626816 H 15.553691 V 7.9896839 c 0,-1.1882914 -0.49996,-1.7914432 -1.500043,-1.7914432 -1.10575,0 -1.659889,0.715401 -1.659889,2.1301529 V 11.413948 H 10.106352 V 8.3283936 c 0,-1.4147519 -0.5543138,-2.1301529 -1.6600628,-2.1301529 -1.000084,0 -1.5000426,0.6031518 -1.5000426,1.7914432 V 13.626816 H 4.6452275 V 7.8190205 c 0,-1.18698
109 0.3022656,-2.1303172 0.9093441,-2.8281631 C 6.1805914,4.2930118 7.0005147,3.9352913 8.0182292,3.9352913 Z"})),ct=t=>o.createElement(a,t,o.createElement("path",{d:"m 23.045963,7.9355562 v 3.7987498 l -0.01469,-0.056 C 23.346411,18.817891 1.2185835,21.36545 1.2185835,21.36545 v -3.836793 m 0.075177,-5.192339 V 8.3573441 M 6.7939469,16.638959 C 5.6484749,16.381008 4.6127423,16.03325 3.7570739,15.581871 2.2780992,14.801689 1.3370697,13.711938 1.2971261,12.241292 M 2.0464728,10.122206 C 4.5831883,3.7286119 20.382021,3.7454996 22.30006,10.110938 M 1.2185835,17.535357 c 0,0 23.2148625,-2.584129 21.7494555,-10.2183133 C 21.611034,0.24754253 2.7448834,0.46882453 1.373585,7.5355232 0.41141246,12.493877 8.5647942,13.74509 15.368311,13.344749 v 1.037311"})),lt=t=>o.createElement(a,t,o.createElement("path",{d:"M15 19.128a9.38 9.38 0 002.625.372 9.337 9.337 0 004.121-.952 4.125 4.125 0 00-7.533-2.493M15 19.128v-.003c0-1.113-.285-2.16-.786-3.07M15 19.128v.106A12.318 12.318 0 018.624 21c-2.331 0-4.512-.645-6.374-1.766l-.001-.109a6.375 6.375 0 0111.964-3.07M12 6.375a3.375 3.375 0 11-6.75 0 3.375 3.375 0 016.75 0zm8.25 2.25a2.625 2.625 0 11-5.25 0 2.625 2.625 0 015.25 0z"})),ht=t=>o.createElement(a,t,o.createElement("path",{d:"M4 6h16M4 12h16M4 18h16"})),pt=t=>o.createElement(a,t,o.createElement("path",{d:"M19 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 11-6.75 0 3.375 3.375 0 016.75 0zM4 19.235v-.11a6.375 6.375 0 0112.75 0v.109A12.318 12.318 0 0110.374 21c-2.331 0-4.512-.645-6.374-1.766z"})),dt=t=>o.createElement(a,t,o.createElement("path",{d:"M19.5 14.25v-2.625a3.375 3.375 0 00-3.375-3.375h-1.5A1.125 1.125 0 0113.5 7.125v-1.5a3.375 3.375 0 00-3.375-3.375H8.25m3.75 9v6m3-3H9m1.5-12H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 00-9-9z"})),ut=t=>o.createElement(a,t,o.createElement("path",{d:"M12 7.5h1.5m-1.5 3h1.5m-7.5 3h7.5m-7.5 3h7.5m3-9h3.375c.621 0 1.125.504 1.125 1.125V18a2.25 2.25 0 01-2.25 2.25M16.5 7.5V18a2.25 2.25 0 002.25 2.25M16.5 7.5V4.875c0-.621-.504-1.125-1.125-1.125H4.125C3.504 3.75 3 4.254 3 4.875V18a2.25 2.25 0 002.25 2.25h13.5M6 7.5h3v3H6v-3z"})),mt=t=>o.createElement(a,t,o.createElement("path",{d:"M6,6 L 18,18 M 18,6 L 6,18"})),ft=t=>o.createElement(a,t,o.createElement("path",{d:"M4.5 12.75l6 6 9-13.5"})),gt=t=>o.createElement(a,t,o.createElement("path",{d:"M10.5 6h9.75M10.5 6a1.5 1.5 0 11-3 0m3 0a1.5 1.5 0 10-3 0M3.75 6H7.5m3 12h9.75m-9.75 0a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m-3.75 0H7.5m9-6h3.75m-3.75 0a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m-9.75 0h9.75"})),yt=t=>o.createElement(a,t,o.createElement("path",{d:"M 4.5 2.5 v 19.2 h 15 v -13.3 h-3 v 10.3 h-9 v-13.2 h 6 v-3 z",strokeWidth:.1,stroke:"none",fill:"currentColor",fillOpacity:"0.666"}),o.createElement("path",{d:i})),wt=t=>o.createElement(a,t,o.createElement("path",{d:i,transform:"scale(-1 1) translate(-21 0)"}),o.createElement("path",{d:"M 16.5 7.75 h 5 v 14 h-5"})),xt=t=>o.createElement(a,t,o.createElement("path",{d:i}),o.createElement("path",{d:i,transform:"scale(0.666) translate(3, 11)"})),bt=t=>o.createElement(a,t,o.createElement("path",{d:"M 1.5867219,1.58672 H 22.413278 V 22.41328 H 1.5867219 Z"}),o.createElement("path",{d:"M 22.007133,15.500122 H 1.97864 m 20.028493,-7 H 1.97864 M 15.492887,1.9858756 V 22.014369 m -7,-20.0284934 V 22.014369",strokeWidth:t.stroke/2||1.1})),vt=t=>o.createElement(a,t,o.createElement("path",{d:i})),_t=t=>o.createElement(a,t,o.createElement("path",{d:"M12 9v6m3-3H9m12 0a9 9 0 11-18 0 9 9 0 0118 0z"})),kt=t=>o.createElement(a,t,o.createElement("path",{d:"M17 17h2a2 2 0 002-2v-4a2 2 0 00-2-2H5a2 2 0 00-2 2v4a2 2 0 002 2h2m2 4h6a2 2 0 002-2v-4a2 2 0 00-2-2H9a2 2 0 00-2 2v4a2 2 0 002 2zm8-12V5a2 2 0 00-2-2H9a2 2 0 00-2 2v4h10z"})),Mt=t=>o.createElement(a,t,o.createElement("path",{d:"M3.98 8.223A10.477 10.477 0 001.934 12C3.226 16.338 7.244 19.5 12 19.5c.993 0 1.953-.138 2.863-.395M6.228 6.228A10.45 10.45 0 0112 4.5c4.756 0 8.773 3.162 10.065 7.498a10.523 10.523 0 01-4.293 5.774M6.228 6.228L3 3m3.228 3.228l3.65 3.65m7.894 7.894L21 21m-3.228-3.228l-3.65-3.65m0 0a3 3 0 10-4.243-4.243m4.242 4.242L9.88 9.88"})),Et=t=>o.createElement(a,(0,s.A)({},t,{stroke:0,fill:!0}),o.createElement("path",{d:"M 11.710829,0.00384705 C 5.0683862,0.16990815 -0.16221405,5.6505729 0.00384705,12.293016 0.16990814,18.686369 5.3178021,23.833614 11.628124,24.082706 18.27056
17,24.248767 23.833939,19.018167 24,12.375723 V 11.710829 C 23.833939,5.0683862 18.353273,-0.16221404 11.710829,0.00384705 Z m 5.187788,5.10021625 c 0.15698,0.00649 0.313636,0.048326 0.458939,0.1313569 0.581214,0.3321223 0.912687,1.0793971 0.580565,1.660611 C 17.605998,7.4772452 16.858724,7.808718 16.27751,7.4765965 15.862357,7.3105352 15.614238,6.8947339 15.614238,6.3965506 L 13.038995,5.8159854 12.208689,9.55236 c 1.826672,0.08303 3.48858,0.664893 4.651007,1.495199 0.664245,-0.664245 1.826673,-0.664245 2.490917,0 0.332122,0.332121 0.49786,0.747274 0.49786,1.245457 0.249091,0.747275 -0.249092,1.327193 -0.830306,1.576284 v 0.49948 c 0,2.740009 -3.155161,4.897506 -7.057597,4.897506 -3.9024357,0 -7.0575963,-2.157497 -7.0575963,-4.897506 V 13.8693 C 3.9896377,13.454147 3.6578398,12.458754 3.989962,11.545418 c 0.2490916,-0.664245 0.9120387,-1.08037 1.5762832,-0.99734 0.4981831,0 0.9133359,0.167358 1.2454581,0.499481 C 8.2232228,10.134222 9.8848065,9.55236 11.545418,9.55236 l 0.913011,-4.1515273 c 0,-0.083031 0.08271,-0.1654124 0.08271,-0.1654125 0.08303,-0.08303 0.166711,-0.084328 0.249741,-0.084328 l 2.906069,0.664893 C 15.946037,5.3800751 16.427678,5.084603 16.898617,5.1040633 Z M 9.3026198,12.293016 c -0.6642443,0 -1.2454583,0.581214 -1.2454583,1.245458 0,0.664245 0.498183,1.245459 1.2454583,1.245459 0.6642442,0 1.2454582,-0.581214 1.2454582,-1.245459 0,-0.664244 -0.581214,-1.245458 -1.2454582,-1.245458 z m 5.4813132,0 c -0.664245,0 -1.245459,0.581214 -1.245459,1.245458 0,0.664245 0.581214,1.245459 1.245459,1.245459 0.664245,0 1.245458,-0.581214 1.245458,-1.245459 0,-0.664244 -0.581213,-1.245458 -1.245458,-1.245458 z m -5.3872557,3.943952 c -0.072653,0 -0.135249,0.04021 -0.1767645,0.123249 -0.1660605,0.16606 -0.1660605,0.332121 0,0.415152 0.8303052,0.830306 2.4905922,0.914633 2.9887762,0.914633 0.498183,0 2.077061,-0.08433 2.990396,-0.914633 -0.08303,-0.08303 -0.084,-0.249092 -0.167034,-0.415152 -0.166061,-0.166062 -0.332121,-0.166062 -0.415152,0 -0.498183,0.581213 -1.660611,0.747598 -2.490917,0.747598 -0.830305,0 -1.992733,-0.166385 -2.4909165,-0.747598 -0.08303,-0.08303 -0.1657365,-0.123249 -0.2383882,-0.123249 z"})),Pt=t=>o.createElement(a,t,o.createElement("path",{d:"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99"})),$t=t=>o.createElement(a,t,o.createElement("path",{d:"M12 9.75 14.25 12m0 0 2.25 2.25M14.25 12l2.25-2.25M14.25 12 12 14.25m-2.58 4.92-6.374-6.375a1.125 1.125 0 0 1 0-1.59L9.42 4.83c.21-.211.497-.33.795-.33H19.5a2.25 2.25 0 0 1 2.25 2.25v10.5a2.25 2.25 0 0 1-2.25 2.25h-9.284c-.298 0-.585-.119-.795-.33Z"})),Lt=t=>o.createElement(a,t,o.createElement("path",{d:"M12 18 l 0 -12 l -8 6 z M 20 18 l 0 -12 l -8 6 z M 2 6 l 0 12 l 1 0 l 0 -10 z"})),Ct=t=>o.createElement(a,t,o.createElement("path",{d:"M9 5l7 7-7 7"})),St=t=>o.createElement(a,t,o.createElement("path",{d:"M15.59 14.37a6 6 0 01-5.84 7.38v-4.8m5.84-2.58a14.98 14.98 0 006.16-12.12A14.98 14.98 0 009.631 8.41m5.96 5.96a14.926 14.926 0 01-5.841 2.58m-.119-8.54a6 6 0 00-7.381 5.84h4.8m2.581-5.84a14.927 14.927 0 00-2.58 5.84m2.699 2.7c-.103.021-.207.041-.311.06a15.09 15.09 0 01-2.448-2.448 14.9 14.9 0 01.06-.312m-2.24 2.39a4.493 4.493 0 00-1.757 4.306 4.493 4.493 0 004.306-1.758M16.5 9a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0z"})),Nt=t=>o.createElement(a,t,o.createElement("path",(0,s.A)({strokeLinecap:"round",strokeLinejoin:"round",d:"M 19.5,12 C 19.5,10.768 19.454,9.547 19.362,8.338 19.21576,6.3582806 17.641719,4.7842398 15.662,4.638 14.504476,4.5506731 13.344609,4.5048098 12.184624,4.5004103 M 19.5,12 l 3,-3 m -3,3 -3,-3 m -12,3 c 0,1.232 0.046,2.453 0.138,3.662 0.1462398,1.979719 1.7202806,3.55376 3.7,3.7 1.295324,0.09777 2.593584,0.143587 3.891661,0.13746 M 4.5,12 l 3,3 m -3,-3 -3,3"},t))),At=t=>o.createElement(a,t,o.createElement("path",{d:"M6 5c7.18 0 13 5.82 13 13M6 11a7 7 0 017 7m-6 0a1 1 0 11-2 0 1 1 0 012 0z"})),Ot=t=>o.createElement(a,t,o.createElement("path",{d:"M12 24V12.5m0 0l3 3m-3-3l-3 3M6.75 19.5a4.5 4.5 0 01-1.41-8.775 5.25 5.25 0 0110.233-2.33 3 3 0 013.758 3.848A3.752 3.752 0 0118 19.5H6.75z"})),Rt=t=>o.createElement(a,t,o.createElement("path",{d:"M2.25 15a4.5 4.5 0 004.5 4.5H18a3.75 3.75 0 001.332-7.257 3 3 0 00-3.7
158-3.848 5.25 5.25 0 00-10.233 2.33A4.502 4.502 0 002.25 15z M 11.5,10 v6 M 8.5,13 h 6"})),jt=t=>o.createElement(a,t,o.createElement("circle",{cx:"12",cy:"12",r:"5"}),o.createElement("circle",{cx:"12",cy:"12",r:"10",strokeDasharray:"2 4"})),It=t=>o.createElement(a,t,o.createElement("path",{d:"M 2 20 h 20",strokeWidth:t.stroke/2||1}),o.createElement("path",{d:"M 2 12 h 20"}),o.createElement("path",{d:"M 2 4 h 20",strokeWidth:2*t.stroke||4})),Tt=t=>o.createElement(a,t,o.createElement("path",{d:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"})),zt=t=>o.createElement(a,t,o.createElement("path",{d:"M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.065 2.572c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.572 1.065c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.065-2.572c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z"}),o.createElement("path",{d:"M15 12a3 3 0 11-6 0 3 3 0 016 0z"})),Ht=t=>o.createElement(a,t,o.createElement("path",{d:"M9 12.75L11.25 15 15 9.75m-3-7.036A11.959 11.959 0 013.598 6 11.99 11.99 0 003 9.749c0 5.592 3.824 10.29 9 11.623 5.176-1.332 9-6.03 9-11.622 0-1.31-.21-2.571-.598-3.751h-.152c-3.196 0-6.1-1.248-8.25-3.285z"})),Ft=t=>o.createElement(a,t,o.createElement("path",{d:"M3 9a2 2 0 012-2h.93a2 2 0 001.664-.89l.812-1.22A2 2 0 0110.07 4h3.86a2 2 0 011.664.89l.812 1.22A2 2 0 0018.07 7H19a2 2 0 012 2v9a2 2 0 01-2 2H5a2 2 0 01-2-2V9z"}),o.createElement("path",{d:"M15 13a3 3 0 11-6 0 3 3 0 016 0z"})),Vt=t=>o.createElement(a,t,o.createElement("path",{d:"M15.75 9V5.25A2.25 2.25 0 0013.5 3h-6a2.25 2.25 0 00-2.25 2.25v13.5A2.25 2.25 0 007.5 21h6a2.25 2.25 0 002.25-2.25V15m3 0l3-3m0 0l-3-3m3 3H9"})),Dt=t=>o.createElement(a,(0,s.A)({},t,{className:`${t.className?t.className:"tw:h-6 tw:w-6"} tw:animate-spin`}),o.createElement("circle",{className:"tw:opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),o.createElement("path",{className:"tw:opacity-85",fill:"currentColor",stroke:"none",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})),Ut=({size:t=6})=>o.createElement(ft,{className:`tw:w-${t} tw:h-${t} tw:text-secondary-content`,stroke:4}),Bt=t=>o.createElement(a,t,o.createElement("path",{d:"M 21.070629,5.6224629 A 5.7508474,5.7508474 0 0 1 16.547219,0.52913011 V 0 H 12.41376 v 16.404252 a 3.474745,3.474745 0 0 1 -6.2403831,2.091334 l -0.0024,-0.0012 0.0024,0.0012 A 3.4735455,3.4735455 0 0 1 9.9924767,13.084289 V 8.8848362 A 7.5938063,7.5938063 0 0 0 3.5205237,21.713559 7.5950059,7.5950059 0 0 0 16.547219,16.405452 V 8.0233494 a 9.8171151,9.8171151 0 0 0 5.72685,1.8309665 V 5.7472464 A 5.7964413,5.7964413 0 0 1 21.070637,5.6225887 Z"})),Wt=t=>o.createElement(a,t,o.createElement("path",{d:"M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 117.072 0l-.548.547A3.374 3.374 0 0014 18.469V19a2 2 0 11-4 0v-.531c0-.895-.356-1.754-.988-2.386l-.548-.547z"})),Gt=t=>o.createElement(a,(0,s.A)({},t,{stroke:t.stroke||2}),o.createElement("path",{d:"M14.74 9l-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 01-2.244 2.077H8.084a2.25 2.25 0 01-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 00-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 013.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 00-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 00-7.5 0"})),Zt=t=>o.createElement(a,(0,s.A)({},t,{stroke:0,fill:!0}),o.createElement("path",{d:"M2.149 0l-1.612 4.119v16.836h5.731v3.045h3.224l3.045-3.045h4.657l6.269-6.269v-14.686h-21.314zm19.164 13.612l-3.582 3.582h-5.731l-3.045 3.045v-3.045h-4.836v-15.045h17.194v11.463zm-3.582-7.343v6.262h-2.149v-6.262h2.149zm-5.731 0v6.262h-2.149v-6.262h2.149z"})),Yt=t=>o.createElement(a,t,o.createElement("path",{d:"M9 17.25v1.007a3 3 0 01-.879 2.122L7.5 21h9l-.621-.621A3 3 0 0115 18.257V17.25m6-12V15a2.25 2.25 0 01-2.25 2.25H5.25A2.25 2.25 0 013 15V5.25m18 0A2.25 2.25 0 0018.75 3H5.25A2.25 2.25 0 003 5.25m18 0V12a2.25 2.25 0 01-2.25 2.25H5.25A2.25 2.25 0 013 12V5.25"})),Jt=t=>o.createElement(a,t,o.createElement("path",{d:"m 2.447878,2.716835 v 4.38448 h 4.38448 M 3.1307,6.882055 c 1.771085,-3.0536 5.075566,-5.10
1727 8.859706,-5.10727 5.65253,0 10.234811,4.58228 10.234811,10.23481 0,5.65253 -4.582281,10.23481 -10.234811,10.23481 -5.440329,0 -9.889258,-4.24469 -10.215624,-9.60291"}),t.text?o.createElement("text",{x:"12",y:"17",style:{fontSize:"15px",textAnchor:"middle",fontWeight:500,fill:"currentColor",stroke:"none"}},t.text):null),qt=t=>o.createElement(a,t,o.createElement("path",{d:"m 1.5,4.5 h 21 v 15 h -21 z"}),o.createElement("path",{d:"m 3.5,19.316406 v -3.708984 z m 2.1035156,0 v -3.708984 z m 2.1035156,0 v -3.708984 z m 2.1035157,0 v -3.708984 z m 4.3789061,0 v -3.708984 z m 2.103516,0 v -3.708984 z m 2.103515,0 v -3.708984 z m 2.103516,0 V 15.607422 Z M 12,19.130859 v -5.082031 z m 0,-8.986328 V 5.0625001 Z M 5.6035156,8.5859371 v -3.708984 z m 12.7929684,0 v -3.708984 z",strokeWidth:t.stroke/2||1.1})),Xt=t=>o.createElement(a,t,o.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:t.stroke||2,d:"M19 16l-7 -7-7 7"})),Kt=t=>o.createElement(a,t,o.createElement("path",{d:"M12 16.5V9.75m0 0l3 3m-3-3l-3 3M6.75 19.5a4.5 4.5 0 01-1.41-8.775 5.25 5.25 0 0110.233-2.33 3 3 0 013.758 3.848A3.752 3.752 0 0118 19.5H6.75z"})),Qt=t=>o.createElement(a,t,o.createElement("path",{d:"M5.121 17.804A13.937 13.937 0 0112 16c2.5 0 4.847.655 6.879 1.804M15 10a3 3 0 11-6 0 3 3 0 016 0zm6 2a9 9 0 11-18 0 9 9 0 0118 0z"})),te=t=>o.createElement(a,t,o.createElement("path",{d:"M12 3v17.25m0 0c-1.472 0-2.882.265-4.185.75M12 20.25c1.472 0 2.882.265 4.185.75M18.75 4.97A48.416 48.416 0 0012 4.5c-2.291 0-4.545.16-6.75.47m13.5 0c1.01.143 2.01.317 3 .52m-3-.52l2.62 10.726c.122.499-.106 1.028-.589 1.202a5.988 5.988 0 01-2.031.352 5.988 5.988 0 01-2.031-.352c-.483-.174-.711-.703-.59-1.202L18.75 4.971zm-16.5.52c.99-.203 1.99-.377 3-.52m0 0l2.62 10.726c.122.499-.106 1.028-.589 1.202a5.989 5.989 0 01-2.031.352 5.989 5.989 0 01-2.031-.352c-.483-.174-.711-.703-.59-1.202L5.25 4.971z"})),ee=t=>o.createElement(a,t,o.createElement("path",{d:"M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"})),ne=t=>o.createElement(a,t,o.createElement("path",{d:"M11.42 15.17L17.25 21A2.652 2.652 0 0021 17.25l-5.877-5.877M11.42 15.17l2.496-3.03c.317-.384.74-.626 1.208-.766M11.42 15.17l-4.655 5.653a2.548 2.548 0 11-3.586-3.586l6.837-5.63m5.108-.233c.55-.164 1.163-.188 1.743-.14a4.5 4.5 0 004.486-6.336l-3.276 3.277a3.004 3.004 0 01-2.25-2.25l3.276-3.276a4.5 4.5 0 00-6.336 4.486c.091 1.076-.071 2.264-.904 2.95l-.102.085m-1.745 1.437L5.909 7.5H4.5L2.25 3.75l1.5-1.5L7.5 4.5v1.409l4.26 4.26m-1.745 1.437l1.745-1.437m6.615 8.206L15.75 15.75M4.867 19.125h.008v.008h-.008v-.008z"})),se=t=>o.createElement(a,t,o.createElement("path",{d:"M14 10l-2 1m0 0l-2-1m2 1v2.5M20 7l-2 1m2-1l-2-1m2 1v2.5M14 4l-2-1-2 1M4 7l2-1M4 7l2 1M4 7v2.5M12 21l-2-1m2 1l2-1m-2 1v-2.5M6 18l-2-1v-2.5M18 18l2-1v-2.5"})),oe=t=>o.createElement(a,t,o.createElement("path",{d:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607ZM10.5 7.5v6m3-3h-6"})),re=t=>o.createElement(a,t,o.createElement("path",{d:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607ZM13.5 10.5h-6"}))},97230:(t,e,n)=>{n.d(e,{B:()=>o});var s=n(14041);const o=({crumbs:t=[],title:e,Link:n=!1})=>(!1===n&&(n=r),s.createElement("div",{className:"tw:tailwind-container tw:p-0"},s.createElement("ul",{className:"tw:flex tw:flex-row tw:items-center tw:gap-2 tw:m-0 tw:py-4",style:{paddingLeft:0}},s.createElement("li",{className:"tw:inline"},s.createElement(n,{href:"/"},s.createElement("b",null,"Home"))),s.createElement(i,null),t.map(((t,e)=>s.createElement(s.Fragment,{key:e},s.createElement("li",{key:e,className:"tw:inline"},s.createElement(n,{href:t.href},t.label)),s.createElement("li",{key:e,className:"tw:inline"},s.createElement(i,null))))),s.createElement("li",{className:"tw:inline"},e)))),r=({href:t,children:e})=>s.createElement("a",{href:t},e),i=()=>s.createElement("li",{className:"tw:inline"},"\xbb")},99005:(t,e,n)=>{n.d(e,{V:()=>s});const s="m18.56 0c-0.4945 0.3515-0.469 0.3065-0.8685 0.437-0.916 0.2995-1.7945 0.135-2.837 0.048-0.3135-0.035-0.6245-0.0555-0.928-0.0575-1.5325-0.0105-2.834 0.439-3.0805 1.694-0.4545 0.2755-0.8725 0.609-1.2865 0.943-0.884 0.6975-1.5495 1.55-2.0035 2.5775-0.62 1.5175-0.06 3.146 0.2175 4.684 0.066 0.36 0.135 0.703 0.172 0.8355 0.0525 0.1865 0.145 0.3645 0.2455 0.5245 0.0235 4e-3 0.1475-0.187 0.177-0.2715 0.043-0.123 0.0385-0.3205-0.0085-0.4905-0.104-0.3825-0.203-0.693-0.2115-0.849-0.015-0.293 0.042-0.5635 0.149-0.6975 0.038-0.0475 0.125 0.1975 0.1025 0.2885-0.0265 0.1095-0.0465 0.297-0.038 0.3835 0.0235 0.293 0.0665 0.6065 0.12 0.8805 0.0685 0.3535 0.098 0.5805 0.0855 0.6685-9e-3 0.064-0.039 0.1285-0.154 0.3265-0.1 0.1735-0.152 0.314-0.16 0.438-0.0085 0.121 0.028 0.4235 0.062 0.4975 0.0495 0.1155 0.1985 0.237 0.3285 0.267 0.1245 0.0475 0.187 0.146 0.251 0.2565 0.1555 0.2965 0.2755 0.6575 0.3945 1.2015 0.058 0.2605 0.1065 0.493 0.122 0.615-0.96 1e-3 -2.1895 0.0015-3.3095 0.0015-0.377 6e-3 -1.058-0.171-1.6825-0.212-0.0905-0.977-0.5195-2.112-1.2535-2.178-0.501-0.0455-0.9165 0.145-1.268 0.9365l0.01 0.0425c0.2075-0.1735 0.4265-0.704 1.2155-0.6675 0.606 0.0275 0.808 1.1745 0.868 1.8645-0.369 0.027-0.683 0.1405-0.847 0.424h-0.0035c0 5e-4 0 0.0015 0.0015 0.0025-0.0015 1e-3 -0.0015 2e-3 -0.0015 3e-3h0.0035c0.169 0.2905 0.4945 0.403 0.877 0.4255 0.2555 7.225 7.047 8.157 8.903 8.157 6.924 0 9.348-4.705 9.7125-6.5685 0.1705 0.794-0.3665 1.8055-0.495 2.552 1.4605-1.6885 1.1965-3.312 0.9295-4.945 0.222 0.264 0.5225 0.4275 0.93 0.337-0.2905-0.194-0.6845-0.058-0.9205-0.8765-0.103-0.3535-0.192-0.6185-0.2805-0.841-0.191-0.7165-0.462-1.401-0.795-2.068-0.281-0.7235-0.0955-1.1925-0.1235-1.8135 0.5055 1.667 0.8215 2.1105 1.4115 2.285-1.484-1.788-0.976-4.5565-1.8145-7.0275 0.3795 0.223 0.8125 0.29 1.2735 0.0175-0.446-0.127-0.891 0.2085-1.531-0.732-0.5405-1.0515-1.3235-1.828-2.2735-2.513-0.509-0.332-1.074-0.555-1.642-0.762 0.5785-0.145 1.2245-0.66 1.2545-1.0445zm-0.9705 5.5535c0.762 0.278 1.602 1.334 1.5925 2.37v0.058c-0.0205 1.407-0.66 2.1635-0.633 3.1005 0.0345 1.1035 0.5095 1.4885 0.604 1.6725-0.162-0.6805-0.257-1.5365-0.043-2.2145 0.275-0.872 0.5525-1.594 0.5325-2.277-0.01-0.16-0.078-0.7585-0.1235-1.0235 0.817 1.179-0.177 2.8935 0.109 4.0155 0.497 1.9545 2.7245 2.2015 2.0615 6.1395-0.5835 3.462-4.5815 6.0895-8.6795 6.0895-3.038 0-8.3025-1.6815-8.5625-7.646 0.61
175-0.044 1.2815-0.216 1.654-0.21 1.126 0 2.412 5e-4 3.381 1e-3 0.182 0.821 0.3185 1.019 1.009 1.566 0.768 0.604 0.947 0.6775 2.083 0.6885 1.1365 0.0115 1.4735-0.232 2.576-1.275 0.238-0.279 0.341-0.6445 0.4565-0.988 1.134-0.0105 1.961-0.0305 2.7745-0.0685 0.8285-0.0375 0.9455 0 2.2805-0.1375-1.335-0.1375-1.452-0.1-2.2805-0.138-0.792-0.036-1.594-0.0565-2.6785-0.0665 0.091-0.4085 0.221-0.8075 0.3595-1.202 0.0855-0.2325 0.186-0.459 0.289-0.6845l0.1125-0.035c0.217-0.077 0.409-0.242 0.4855-0.465 0.0985-0.2955 0.0285-0.6275-0.162-0.869-0.0655-0.0905-0.147-0.206-0.1805-0.257-0.1005-0.159-0.103-0.2475-0.018-0.8385 0.0715-0.495 0.0795-0.754 0.03-1.005-0.01-0.1435-0.011-0.4385-0.0155-0.518 0.038 0.021 0.1205 0.209 0.204 0.4635 0.083 0.2555 0.0965 0.3085 0.1155 0.526 0.021 0.247-0.0715 0.43-0.1475 0.7985-0.038 0.19-0.0715 0.3665-0.0715 0.3905 0 0.0255 0.018 0.0795 0.037 0.1215 0.0445 0.094 0.128 0.226 0.1435 0.226 0.2725-0.3005 0.4325-0.6715 0.575-1.048 0.15-0.426 0.194-0.878 0.299-1.3165 0.085-0.382 0.183-0.7645 0.2135-1.1565 0.0615-0.765 0.0255-1.305-0.1435-2.102-0.0405-0.18-0.1575-0.5235-0.239-0.6855zm-2.68 3.7685c0.2925-0.0035 0.582 0.032 0.8575 0.1115 0.3745 0.1435 0.427 0.478 0.496 0.8535 0.0385 0.24 0.037 0.4125-0.0065 0.6945-0.0305 0.409-0.193 0.7255-0.548 0.948-0.5355 0.099-1.108 0.1945-1.562-0.16-0.381-0.525-0.6105-1.1885-0.523-1.8355 0.0555-0.2655 0.179-0.4035 0.433-0.486 0.2735-0.0785 0.563-0.1215 0.853-0.126zm-4.4415 0.0475c0.2735-0.0025 0.55 0.0265 0.702 0.1235 0.6525 0.4415 0.443 1.16 0.185 1.7905-0.3755 0.8255-1.1875 0.795-1.9745 0.7885-0.4355-0.1275-0.4755-0.4845-0.5385-0.866-0.054-0.3685-0.169-0.7635-0.073-1.134 0.2465-0.596 1.1475-0.6645 1.699-0.7025zm9.9515 0.103c0.0035 1.5865 0.2745 2.366 0.8185 3.4895-0.3205-0.6115-0.7785-0.9595-0.949-1.6905-0.326-1.4115 0.0255-1.3325 0.1305-1.799zm-7.9065 1.149c0.086 0.087 0.1275 0.207 0.202 0.3025 0.0575-0.0985 0.1165-0.1965 0.1905-0.284 0.0385 1e-3 0.0855 0.077 0.128 0.213 0.182 0.503 0.2175 1.0565 0.4535 1.54 0.2205 0.35-0.0805 0.554-0.411 0.57-0.241-5e-4 -0.343-0.165-0.4845-0.328-0.0365 0.1065-0.106 0.175-0.189 0.247-0.211 0.177-0.6245 0.1115-0.6885-0.1675 0.085-0.533 0.3565-1.0225 0.5345-1.5335 0.0885-0.1865 0.0895-0.3295 0.2645-0.5595zm-3.096 2.6925c0.1065 0 0.399 0.1985 0.4585 0.3105 0.041 0.0745 0.1345 0.3645 0.141 0.435 0.0105 0.084-0.015 0.283-0.041 0.337-0.019 0.0385-0.0335 0.044-0.0555 0.019-0.0185-0.021-0.2635-0.491-0.42-0.802-0.123-0.249-0.136-0.2995-0.083-0.2995zm6.111 0.1555c4e-3 5e-4 0.01 2e-3 0.0155 0.0035 0.033 0.0135 0.01 0.1305-0.114 0.5555-0.0235 0.128-0.0805 0.229-0.164 0.313-0.0275 0-0.04-0.032-0.083-0.2095-0.0365-0.1515-0.0405-0.2865-0.015-0.4075 0.044-0.1515 0.222-0.198 0.3605-0.255zm-0.7415 0.9265c0.0105-2e-3 0.0205 0.0035 0.0335 0.014 0.045 0.0315 0.0515 0.1145 0.0215 0.277-0.0365 0.209-0.0445 0.232-0.0985 0.2535-0.0235 0.0105-0.0655 0.018-0.0935 0.018-0.0505-9e-3 -0.0635-0.05-0.0515-0.112 0-0.13 0.038-0.243 0.124-0.3765 0.0325-0.05 0.049-0.0715 0.0645-0.074zm-4.3165 0.0095c0.0345 0 0.1385 0.075 0.177 0.127 0.043 0.055 0.092 0.3825 0.0645 0.439-0.0315 0.071-0.1855 0.0355-0.228-0.053-0.026-0.053-0.0875-0.339-0.0875-0.407 0-0.063 0.0305-0.106 0.074-0.106zm3.9455 0.0865c0.042 0.06 0.053 0.137 0.044 0.306l-0.0085 0.154-0.044 0.044c-0.0265 0.0245-0.0715 0.0545-0.0985 0.067-0.0595 0.028-0.105 0.0305-0.1135 8e-3 -0.01-0.03 7e-3 -0.221 0.0255-0.2855 0.0215-0.0665 0.118-0.265 0.15-0.307 0.0145-0.0385 0.0315 0.0095 0.045 0.0135zm-2.5105-9e-3c0.0905 0.023 0.1305 0.1045 0.18 0.1785l0.0335 0.066-0.047 0.1635c-0.025 0.09-0.0515 0.171-0.0595 0.18-9e-3 0.01-0.0425 0.015-0.092 0.0145-0.132-0.0035-0.147-9e-3 -0.1825-0.063l-0.033-0.049 0.028-0.1375c0.0405-0.198 0.06-0.2575 0.105-0.3085 0.0235-0.0275 0.047-0.0425 0.0675-0.0445zm-0.8355 0.1415 0.0745 0.0745 0.0125 0.1685c0.0065 0.092 0.0095 0.1775 0.0045 0.188-0.0045 0.0145-0.0315 0.0185-0.115 0.0185h-0.1085c-0.058-0.0635-0.076-0.141-0.1005-0.221-0.057-0.2405-0.057-0.35 2e-3 -0.3645 0.0965 6e-3 0.16 0.076 0.2305 0.136zm2.9-0.1155c0.118 0.0315 0.0945 0.219 0.094 0.353-9e-3 0.217-0.0175 0.262-0.0455 0.29-0.0485 0.0485-0.1835 0.0215-0.249-0.0505-0.0215-0.026-0.0235-0.034-0.006
15-0.1395 0.0195-0.1285 0.0445-0.2085 0.1-0.3185 0.0405-0.079 0.0785-0.1285 0.107-0.1345zm-2.663 0.01c0.0065-5e-4 0.017 0 0.027 1e-3 0.075 6e-3 0.145 0.055 0.207 0.145l0.05 0.0735c0.0045 0.1205 0 0.2475-0.0215 0.3595-0.013 0.0065-0.067 0.0165-0.12 0.0215-0.092 0.0085-0.1005 0.0065-0.1325-0.0215-0.0445-0.038-0.057-0.1085-0.068-0.3425-0.0065-0.191-2e-3 -0.2335 0.058-0.2365zm1.1345 0.04c0.0805 0.017 0.1315 0.06 0.154 0.1305 0.018 0.0605 0.029 0.399 0.0115 0.4225-6e-3 0.01-0.044 0.0225-0.0875 0.028-0.162 0.0205-0.305 5e-3 -0.319-0.0335-0.018-0.044 0.1025-0.48 0.147-0.534 0.019-0.042 0.065-0.0095 0.094-0.0135zm1.049 3e-3c0.0355-0.0035 0.0735 0.0305 0.1105 0.103 0.03 0.0605 0.0345 0.0815 0.0345 0.217 0 0.108-0.0065 0.1545-0.018 0.1645-0.01 8e-3 -0.0505 0.0225-0.0935 0.0335-0.075 0.0195-0.0915 0.0215-0.115 0.0135l-0.1125-0.0205 0.0085-0.067c8e-3 -0.0875 0.0655-0.2815 0.106-0.3655 0.024-0.05 0.0515-0.075 0.0795-0.0785zm-0.489 0.0015c0.0235-1e-3 0.0345 0.0045 0.0495 0.021 0.0355 0.042 0.0805 0.166 0.109 0.2985 0.038 0.1865 0.038 0.186-0.0435 0.2105-0.0355 0.011-0.1105 0.0225-0.164 0.0255-0.1765 9e-3 -0.19-0.0015-0.1685-0.1575 0.017-0.139 0.0855-0.358 0.115-0.374 0.032-0.017 0.069-0.0165 0.1025-0.024zm-8.9965 0.7045c0.0015-5e-4 0.0035 0 0.0035 0 0.0045 0.0975 0.0045 0.196 0.0065 0.294-0.2475-0.019-0.4295-0.078-0.4295-0.1475 0-0.0685 0.1755-0.127 0.4195-0.1465zm0.4325 0.0085c0.2005 0.025 0.339 0.0775 0.3365 0.138 0 0.061-0.134 0.113-0.333 0.1375-2e-3 -0.0915-2e-3 -0.1835-0.0035-0.2755zm9.363 0.2665c0.017-0.0015 0.0245-3e-3 0.0505-5e-4 0.104 0.0105 0.119 0.017 0.119 0.052 0 0.046-0.079 0.1845-0.1325 0.2325-0.025 0.024-0.0595 0.044-0.0715 0.044-0.06 0-0.095-0.1265-0.067-0.243 0.017-0.063 0.048-0.0825 0.1015-0.085zm-0.3775 0.0415c0.0465-4e-3 0.0915 0.0085 0.1365 0.0145-0.013 0.1315-0.072 0.239-0.1815 0.3105-0.027 0-0.0405-0.0515-0.0405-0.164 0-0.134 7e-3 -0.1595 0.0855-0.161zm-0.414 0.0485c0.0965 0 0.1815 0.0045 0.1855 0.01 0.018 0.017-0.034 0.146-0.1105 0.277-0.0655 0.1165-0.075 0.125-0.1155 0.128-0.159-0.018-0.1545-0.2045-0.179-0.3325 0-0.076 0.017-0.0825 0.2195-0.0825zm-1.5045 0.0145c0.1105 2e-3 0.1535 0.0185 0.1535 0.061 0 0.054-0.041 0.1615-0.0645 0.175-0.0355 0.0195-0.0385 0.0185-0.1085-0.0545-0.1105-0.124-0.123-0.147 0.0195-0.1815zm0.532 0.0055c2e-3 3e-3 0.0235 0.042 0.045 0.086 0.047 0.0915 0.0505 0.1315 0.017 0.162-0.079 0.045-0.0955 0.0195-0.167-0.026-0.083-0.0785-0.1485-0.184-0.127-0.206 0.074-0.0265 0.1555-0.0165 0.232-0.016zm0.211 0.0025 0.1975 0.0035c0.077 0 0.1435 4e-3 0.147 0.01 0.0135 0.012-0.03 0.269-0.0535 0.327-0.027 0.065-0.1215 0.0655-0.1705-0.0115-0.07-0.1105-0.116-0.2035-0.1175-0.2675z"},99025:(t,e,n)=>{n.d(e,{Sr:()=>et,Ru:()=>nt});const s=JSON.parse('{"id":"plugin-annotations","r":"4.6.0"}'),o={en:JSON.parse('{"plugin-annotations:canvas":"canvas","plugin-annotations:cut":"Cut","plugin-annotations:contrast":"contrasting fabric","plugin-annotations:cutOnFold":"Cut on fold","plugin-annotations:cutOnFoldAndGrainline":"Cut on fold / Grainline","plugin-annotations:fabric":"main fabric","plugin-annotations:altFabric1":"alternative fabric","plugin-annotations:altFabric2":"alternative fabric #2","plugin-annotations:altFabric3":"alternative fabric #3","plugin-annotations:altFabric4":"alternative fabric #4","plugin-annotations:facing":"facing","plugin-annotations:from":"from","plugin-annotations:fusible":"fusible interfacing","plugin-annotations:grainline":"Grainline","plugin-annotations:interfacing":"interfacing","plugin-annotations:lining":"lining","plugin-annotations:mirrored":"mirrored","plugin-annotations:noName":"No name","plugin-annotations:noVersion":"No version","plugin-annotations:onBias":"on the bias","plugin-annotations:onFold":"on the fold","plugin-annotations:onFoldAndBias":"on the fold, and on bias","plugin-annotations:ribbing":"ribbing","plugin-annotations:rigidinterfacing":"rigid interfacing","plugin-annotations:sewTogether":"Sew together","plugin-annotations:specialty":"specialty fabric (see pattern instructions)","plugin-annotations:underside":"underside fabric","plugin-annotations:supportFreeSewingBecomeAPatron":"Support FreeSewing, become a patron","plugin-annotations:theBlackOutsideOfThisBoxShouldMeasure":"The (black) outside of this box should measure","plugin-annotations:theWhiteInsideOfThisBoxShouldMeasure":"The (white) inside of this box should measure"}')},r=[{name:"button",def:t=>`\n<g id="button"\ntransform="scale(${t})">\n <circle\n cx="0" cy="0" r="3.4"\n class="mark"\n ></circle>\n <circle cx="-1" cy="-1" r="0.5" class="no-stroke fill-mark"></circle>\n <circle cx="1" cy="-1" r="0.5" class="no-stroke fill-mark"></circle>\n <circle cx="1" cy="1" r="0.5" class="no-stroke fill-mark"></circle>\n <circle cx="-1" cy="1" r="0.5" class="no-stroke fill-mark"></circle>\n</g>`}
1,{name:"buttonhole",def:t=>`\n<g id="buttonhole"\ntransform="scale(${t})">\n <path\n class="mark"\n d="M -1,-5 L 1,-5 L 1,5 L -1,5 z"\n ></path>\n</g>`},{name:"buttonhole-start",def:t=>`\n<g id="buttonhole-start"\ntransform="scale(${t})">\n <path\n class="mark"\n d="M -1,-10 L 1,-10 L 1,0 L -1,0 z"\n ></path>\n</g>`},{name:"buttonhole-end",def:t=>`\n<g id="buttonhole-end"\ntransform="scale(${t})">\n <path\n class="mark"\n d="M -1,0 L 1,0 L 1,10 L -1,10 z"\n ></path>\n</g>`},{name:"snap-stud-grad",def:t=>`\n<radialGradient id="snap-stud-grad" cx="50%" cy="50%" r="50%" fx="50%" fy="50%"\ntransform="scale(${t})">\n <stop offset="30%" style="stop-color:rgb(235,235,235); stop-opacity:1"></stop>\n <stop offset="80%" style="stop-color:rgb(100,100,100);stop-opacity:1"></stop>\n</radialGradient>`},{name:"snap-stud",def:t=>`\n<g id="snap-stud"\ntransform="scale(${t})">\n <circle id="snap-stud-circle-edge" cx="0" cy="0" r="3.4"\n style="stroke:#666;fill:#dddddd;stroke-width:0.3;"\n ></circle>\n <circle id="snap-stud-circle-middle" cx="0" cy="0" r="1.8"\n style="stroke:none;fill:url(#snap-stud-grad);"\n ></circle>\n <path\n id="snap-stud-lines" style="fill:none;stroke:#666; stroke-width:0.2;"\n d="M -2,0 L -3,0 M 2,0 L 3,0 M 0,2 L 0,3 M 0,-2 L 0,-3 M 1.5,1.5 L 2.1,2.1 M -1.5,1.5 L -2.1,2.1 M -1.5,-1.5 L -2.1,-2.1 M 1.5,-1.5 L 2.1,-2.1"\n ></path>\n</g>`},{name:"snap-socket",def:t=>`\n<g id="snap-socket"\ntransform="scale(${t})">\n <circle id="snap-socket-circle-edge" cx="0" cy="0" r="3.4"\n style="stroke:#666;fill:#bbbbbb;stroke-width:0.3;"\n ></circle>\n <circle id="snap-socket-circle-middle" cx="0" cy="0" r="2"\n style="stroke:#666;fill:#dddddd; stroke-width:0.4;"\n ></circle>\n <path\n style="fill:none;stroke:#666; stroke-width:0.5;"\n d="M -1.7,-1 L -1.7,1 M 1.7,-1 L 1.7,1" id="snap-socket-lines"\n ></path>\n</g>`},{name:"eyelet",def:'\n<g id="eyelet">\n <circle id="eyelet-circle" cx="0" cy="0" r="3.4" class="no-full stroke-mark mark" stroke-width="1" fill="none" stroke="currentColor">\n </circle>\n</g>'}];var i=n(57416);const a=[{name:"logo",def:t=>`<g id="logo" transform="scale(${2*t}) translate(-12.55 -18)"><path class="logo" fill="currentColor" d="${i.VI}"/></g>`}],c=[{name:"notch",def:t=>`\n<g id="notch" transform="scale(${t})">\n <circle cy="0" cx="0" r="1.4" class="fill-note"></circle>\n <circle cy="0" cx="0" r="2.8" class="note"></circle>\n</g>`},{name:"bnotch",def:t=>`\n<g id="bnotch" transform="scale(${t})">\n <path d="M -1.1 -1.1 L 1.1 1.1 M 1.1 -1.1 L -1.1 1.1" class="note"></path>\n <circle cy="0" cx="0" r="2.8" class="note"></circle>\n</g>`}],l={classes:"center",dy:-1,force:!1,id:"banner",repeat:10,spaces:12},h={banner:function(t,{paths:e,store:n,complete:s}){if(!s&&!t.force)return;const o={...l,...t},r=n.generateMacroIds(["banner"],o.id);e[r.banner]=o.path.clone().setClass("hidden").attr("data-text-dy",o.dy).attr("data-text-class",o.classes);const i=" ".repeat(o.spaces);for(let a=0;a<o.repeat;a++)e[r.banner].addText(o.text).addText(i);return e[r.banner].addText(o.text),n.storeMacroIds(o.id,{paths:r}),n.getMacroIds(o.id)},rmbanner:(t=l.id,{store:e,part:n})=>e.removeMacroNodes(t,"banner",n)},p={classes:{text:"text-xs fill-note",box:"stroke-xs stroke-note lashed"},dy:4,id:"bannerbox",margin:15,repeat:99,spaces:12,text:""},d={bannerbox:function(t,{Point:e,paths:n,Path:s,macro:o,log:r,store:i,complete:a}){if(!a&&!t.force)return;const c={...p,...t,classes:p.classes};t.classes&&(c.classes={...c.classes,...t.classes}),c.topLeft&&"function"==typeof c.topLeft.attr||(r.warn("Bannerbox macro called without a valid topLeft point. Using (0,0) for topLeft."),c.topLeft=new e(0,0)),c.bottomRight&&"function"==typeof c.bottomRight.attr||(r.warn("Bannerbox macro called without a valid bottomRight point. Using (6660,666) for bottomRight."),c.bottomRight=new e(666,666));const l=i.generateMacroIds(["box"],c.id),h=Math.sqrt(2*Math.pow(c.margin,2));return n[l.box]=(new s).move(c.topLeft.shift(135,h)).line(new e(c.bottomRight.x,c.topLeft.y).shift(45,h)).line(c.bottomRight.shift(315,h)).line(new e(c.topLeft.x,c.bottomRight.y).shift(225,h)).line(c.topLeft.shift(135,h)).close().addClass(c.classes.box),o("banner",{id:c.id,path:n[l.box],text:c.text,className:c.classes.text,repeat:c.repeat,spaces:c.spaces,dy:c.dy}),i.storeMacroIds(c.id,{paths:l}),i.getMacroIds(c.id)},rmbannerbox:(t=p.id,{macro:e,store:n,part:s})=>(e("rmbanner",t),n.removeMacroNodes(t,"bannerbox",s))},u={anchor:!1,angle:0,bartackAlong:!1,bartackFractionAlong:!1,classes:"stroke-sm stroke-mark",density:3,end:1,from:!1,id:"bartack",length:15,path:!1,start:0,to:!1,width:3},m=(t,e,n)=>t?((t,{Path:e})=>{let n=(new e).move(t.path1[0]);for(const s in t.path1)t.path1[s]&&(n=n.line(t.path1[s])),t.path2[s]&&(n=n.line(t.path2[s]));return n})(((t,e)=>{let n=t.offset(e.width/2),s=t.offset(e.width/-2),o=n.length(),r=s.length();if(r>o){let t=s;s=n,n=t,o=r}let i={path1:[n.start()],path2:[s.start()]},a=Math.ceil(o/e.width*e.density);for(let c=1;c<a;c++)i.path1.push(n.shiftFractionAlong(1/a*c)),i.path2.push(s.shiftFractionAlong(1/a*c));return i})(t,e),n):null;function f(t,e){if(!e.complete&&!t.force)return;const n={...u,...t},{Path:s,paths:o}=e;n.angle<0&&(n.angle=360+n.angle%-360);let r=!1;
1if(n.anchor)r=(new s).move(n.anchor).line(n.anchor.shift(n.angle,n.length));else if(n.from&&n.to)r=(new s).move(n.from).line(n.to);else if(n.path){let t=!1,e=!1;if(n.bartackAlong)r=n.path.clone();else if(n.bartackFractionAlong){if(n.start===n.end)return null;if(n.start>n.end){const t=n.start;n.start=n.end,n.end=t}n.start>0&&(t=n.path.shiftFractionAlong(n.start)),n.end<1&&(e=n.path.shiftFractionAlong(n.end)),r=t&&e?n.path.split(t).pop().split(e).shift():t?n.path.split(t).pop():e?n.path.split(e).shift():n.path.clone()}}const i=e.store.generateMacroIds(["stitches"],n.id);return o[i.stitches]=m(r,n,e).attr("class",n.classes),e.store.storeMacroIds(n.id,{paths:i}),e.store.getMacroIds(n.id)}const g=(t="bartack",e=u.id,{store:n,part:s})=>n.removeMacroNodes(e,t,s),y={bartack:(t,e)=>f(t,e),bartackAlong:(t,e)=>f({...t,id:"bartackalong",bartackFractionAlong:!1,bartackAlong:!0,anchor:!1,from:!1,to:!1},e),bartackFractionAlong:(t,e)=>f({...t,id:"bartackfractionalong",bartackFractionAlong:!0,bartackAlong:!1,anchor:!1,from:!1,to:!1},e),rmbartack:(t,e)=>g("bartack",t,e),rmbartackAlong:(t,e)=>g("bartackalong",t,e),rmbartackFractionAlong:(t,e)=>g("bartackfractionalong",t,e)},w={classes:{box:"lining dotted stroke-sm",cross:"lining dotted stroke-sm",text:"center fill-lining"},id:"crossbox",offset:.1,text:""},x={crossbox:function(t,{points:e,Point:n,paths:s,Path:o,complete:r,store:i,log:a}){if(!r&&!t.force)return;const c={...w,...t,classes:w.classes};t.classes&&(c.classes={...c.classes,...t.classes}),c.topLeft&&"function"==typeof c.topLeft.attr||(a.warn("Crossbox macro called without a valid topLeft point. Using (0,0) for topLeft."),c.topLeft=new n(0,0)),c.bottomRight&&"function"==typeof c.bottomRight.attr||(a.warn("Crossbox macro called without a valid bottomRight point. Using (666,666) for bottomRight."),c.bottomRight=new n(666,666));const l=i.generateMacroIds(["box","cross","text"],c.id),h={paths:{box:l.box,cross:l.cross},points:{text:l.text}},p=Math.abs(c.topLeft.dx(c.bottomRight))>Math.abs(c.topLeft.dy(c.bottomRight))?Math.abs(c.topLeft.dx(c.bottomRight))*c.offset:Math.abs(c.topLeft.dy(c.bottomRight))*c.offset;return s[h.paths.box]=(new o).move(c.topLeft).line(new n(c.topLeft.x,c.bottomRight.y)).line(c.bottomRight).line(new n(c.bottomRight.x,c.topLeft.y)).line(c.topLeft).close().attr("class",c.classes.box),s[h.paths.cross]=(new o).move(c.topLeft.shift(315,p)).line(new n(c.bottomRight.x,c.topLeft.y).shift(225,p)).line(c.bottomRight.shift(135,p)).line(new n(c.topLeft.x,c.bottomRight.y).shift(45,p)).line(c.topLeft.shift(315,p)).line(c.bottomRight.shift(135,p)).move(new n(c.bottomRight.x,c.topLeft.y).shift(225,p)).line(new n(c.topLeft.x,c.bottomRight.y).shift(45,p)).attr("class",c.classes.box),c.text?e[h.points.text]=c.topLeft.shiftFractionTowards(c.bottomRight,.5).addText(c.text,c.classes.text):delete h.points.text,i.storeMacroIds(c.id,h),i.getMacroIds(c.id)},rmcrossbox:(t=w.id,{store:e,part:n})=>e.removeMacroNodes(t,"crossbox",n)},b=[["cutlist.addCut",v],["cutlist.setCut",function(t,e){return _(t),v(t,e)}],["cutlist.removeCut",_],["cutlist.setGrain",function(t,e=!1,n="grainline"){const s=t.get("activePart"),o=["cutlist",s,"grain"];if(!1===e)return t.log.warn("Using setGrain() to remove the grain is deprecated. Use removeGrain() instead"),t.unset(o);if("number"!=typeof e)return t.log.error("Called part.setGrain() with a value that is not a number"),t;return t.set(["cutlist",s,"grainOrigin"],n),t.set(o,e)}],["cutlist.removeGrain",function(t){return t.unset(["cutlist",t.get("activePart"),"grain"])}],["cutlist.getGrainOrigin",function(t){return t.get(["cutlist",t.get("activePart"),"grainOrigin"],null)}],["cutlist.setCutOnFold",function(t,e,n){const s=["cutlist",t.get("activePart"),"cutOnFold"];if(!1===e&&void 0===n)return t.log.warn("Using setCutOnFold() to remove the cutonfold is deprecated. Use removeCutOnFold() instead"),t.unset(s);isNaN(e.x)||isNaN(e.y)||isNaN(n.x)||isNaN(n.y)?t.log.error("Called part.setCutOnFold() but at least one parameter is not a Point instance"):t.set(s,[e,n]);return t}],["cutlist.removeCutOnFold",function(t){return t.unset(["cutlist",t.get("activePart"),"cutOnFold"])}],["cutlist.getCutFabrics",function(t,e){const n=t.get("cutlist"),s=e.only?[].concat(e.only):Object.keys(n),o=[];
1return s.forEach((t=>{if(n[t]?.materials)for(var e in n[t].materials)o.includes(e)||o.push(e)})),o}]];function v(t,e={}){if(Array.isArray(e)){for(const n of e)v(t,n);return t}const{cut:n=2,from:s="fabric",identical:o=!1,onBias:r=!1,onFold:i=!1}=e,a=t.get("activePart");if(!1===n)return!1===s?t.unset(["cutlist",a,"materials"]):t.unset(["cutlist",a,"materials",s]),t;if(!(Number.isInteger(n)&&n>-1))return t.log.error("Tried to set cut to a value that is not a positive integer"),t;if("string"!=typeof s)return t.log.warn("Tried to set material to a value that is not a string"),t;const c=["cutlist",a,"materials",s],l=t.get(c,[]);return t.set(c,l.concat({cut:n,identical:o,onBias:r,onFold:i})),t}function _(t,e=!1){return v(t,{cut:!1,from:e})}const k={classes:{lead:"text-xs bold",title:"text bold",text:"text-xs",link:"text-sm fill-note bold",metric:"text-xs center",imperial:"text-xs center",imperialBox:"scalebox imperial fill-current",metricBox:"scalebox metric fill-bg"},lead:"FreeSewing",link:"FreeSewing.org/patrons/join",text:"plugin-annotations:supportFreeSewingBecomeAPatron",title:!1,force:!1},M={scalebox:{metric:[[10,5,"1cm","0.5cm"],[20,10,"2cm","1cm"],[30,15,"3cm","1.5cm"],[40,20,"4cm","2cm"],[50,25,"5cm","2.5cm"],[60,30,"6cm","3cm"],[70,35,"7cm","3.5cm"],[80,40,"8cm","4cm"],[90,45,"9cm","4.5cm"],[100,50,"10cm","5cm"]],imperial:[[12.7,6.35,'1/2"','1/4"'],[25.4*.875,12.7,'7/8"','1/2"'],[31.75,15.875,'1 1/4"','5/8"'],[41.275,25.4*.875,'1 5/8"','7/8"'],[50.8,25.4,'2"','1"'],[25.4*2.375,31.75,'2 3/8"','1 1/4"'],[25.4*2.875,25.4*1.5,'2 7/8"','1 1/2"'],[82.55,41.275,'3 1/4"','1 5/8"'],[25.4*3.625,47.625,'3 5/8"','1 7/8"'],[101.6,50.8,'4"','2"']]},miniscale:[[10,"1cm",25.4*.375,'3/8"'],[13,"1.3cm",12.7,'1/2"'],[16,"1.6cm",15.875,'5/8"'],[19,"1.9cm",25.4*.75,'3/4"'],[22,"2.2cm",25.4*.875,'7/8"'],[25,"2.5cm",25.4,'1"']]},E=function(t=!1,{store:e,part:n},s){return t||(t=s),e.removeMacroNodes(t,s,n)},P={scalebox:function(t,{store:e,points:n,paths:s,scale:o,Point:r,Path:i,complete:a,log:c}){if(!a&&!t.force)return;const l={...k,id:"scalebox",...t,classes:k.classes};t.classes&&(l.classes={...l.classes,...t.classes});const h=Math.round(10*Math.max(.1,Math.min(1,o)))-1,[p,d,u,m]=M.scalebox.metric[h],[f,g,y,w]=M.scalebox.imperial[h];l.at&&"function"==typeof l.at.attr||(c.warn("Scalebox macro called without a valid at point. Using (0,0) for at."),l.at=new r(0,0));const x=e.generateMacroIds(["metric","imperial","textLead","textMetric","textImperial","textTitle","textText","textLink"],l.id),b={mtl:new r(l.at.x-p/2,l.at.y-d/2),mtr:new r(l.at.x+p/2,l.at.y-d/2),mbl:new r(l.at.x-p/2,l.at.y+d/2),mbr:new r(l.at.x+p/2,l.at.y+d/2),itl:new r(l.at.x-f/2,l.at.y-g/2),itr:new r(l.at.x+f/2,l.at.y-g/2),ibl:new r(l.at.x-f/2,l.at.y+g/2),ibr:new r(l.at.x+f/2,l.at.y+g/2)},v={lead:new r(l.at.x-45*o,l.at.y-15*o),metric:new r(l.at.x,l.at.y+20*o),imperial:new r(l.at.x,l.at.y+24*o)};if(v.title=v.lead.shift(-90,10*o),v.text=v.title.shift(-90,12*o),v.link=v.text.shift(-90,5*o),l.rotate){l.rotate=Number(l.rotate);for(const t in b)b[t]=b[t].rotate(l.rotate,l.at);for(const t in v)v[t]=v[t].rotate(l.rotate,l.at),v[t].attr("data-text-transform",`rotate(${-1*l.rotate}, ${v[t].x}, ${v[t].y})`,!0)}s[x.imperial]=(new i).addClass(l.classes.imperialBox).move(b.itl).line(b.ibl).line(b.ibr).line(b.itr).line(b.itl).close(),s[x.metric]=(new i).addClass(l.classes.metricBox).move(b.mtl).line(b.mbl).line(b.mbr).line(b.mtr).line(b.mtl).close(),n[x.textLead]=v.lead.addText(l.lead,l.classes.lead);let _=l.title;return _||(_=e.data?.name||"plugin-annotations:noName",-1!==_.indexOf("@freesewing/")&&(_=_.replace("@freesewing/",""))),n[x.textTitle]=v.title.addText(_,l.classes.title).attr("data-text","v"+(e.data?.version||"No Version")),n[x.textText]=v.text.addText(l.text,l.classes.text),n[x.textLink]=v.link.addText(l.link,l.classes.link).attr("data-text-lineheight",4),n[x.textMetric]=v.metric.attr("data-text","plugin-annotations:theWhiteInsideOfThisBoxShouldMeasure").attr("data-text",u).attr("data-text","x").attr("data-text",m).attr("data-text-class",l.classes.metric),n[x.textImperial]=v.imperial.attr("data-text","plugin-annotations:theBlackOutsideOfThisBoxShouldMeasure").attr("data-text",y).attr("data-text","x").attr("data-text",w).attr("data-text-class",l.classes.imperial),e.storeMacroIds(l.id,{points:{textLead:x.textLead,textMetric:x.textMetric,textImperial:x.textImperial,textTitle:x.textTitle,textText:x.textText,textLink:x.textLink},paths:{metric:x.metric,imperial:x.imperial}}),e.getMacroIds(l.id)},miniscale:function(t,{points:e,paths:n,scale:s,Point:o,Path:r,complete:i,log:a,store:c}){if(!i&&!t.force)return;const l={...k,id:"miniscale",...t,classes:k.classes};t.classes&&(l.classes={...l.classes,...t.classes});const h=Math.ceil(6*Math.max(.1,Math.min(1,s)))-1,[p,d,u,m]=M.miniscale[h];l.at&&"function"==typeof l.at.attr||(a.warn("Scalebox macro called without a valid at point. Using (0,0) for at."),l.at=new o(0,0));const f=c.generateMacroIds(["metric","imperial","textMetric","textImperial"],l.id),g={mtl:new o(l.at.x-p/2,l.at.y-p/2),mtr:new o(l.at.x+p/2,l.at.y-p/2),mbl:new o(l.at.x-p/2,l.at.y+p/2),mbr:new o(l.at.x+p/2,l.at.y+p/2),itl:new o(l.at.x-u/2,l.at.y-u/2),itr:new o(l.at.x+u/2,l.at.y-u/2),ibl:new o(l.at.x-u/2,l.at.y+u/2),ibr:new o(l.at.x+u/2,l.at.y+u/2)},y={metric:new o(l.at.x,l.at.y-2*s),imperial:new o(l.at.x,l.at.y+8*s)};if(l.rotate){l.rotate=Number(l.rotate);for(const t in g)g[t]=g[t].rotate(l.rotate,l.at);for(const t in y)y[t]=y[t].rotate(l.rotate,l.at).attr("data-text-transform",`rotate(${-1*l.rotate}, ${y[t].x}, ${y[t].y})`,!0)}return n[f.imperial]=(new r).attr("class","scalebox imperial fill-current").move(g.itl).line(g.ibl).line(g.ibr).line(g.itr).line(g.itl).close(),n[f.metric]=(new r).attr("class","scalebox metric fill-bg").move(g.mtl).line(g.mbl).line(g.mbr).line(g.mtr).line(g.mtl).close(),e[f.textMetric]=y.metric.addText(`${d} x ${d}`,l.classes.metric),e[f.textImperial]=y.imperial.addText(`${m} x ${m}`,l.classes.imperial),c.storeMacroIds(l.id,{points:{textMetric:f.textMetric,textImperial:f.textImperial},paths:{metric:f.metric,imperial:f.imperial}}),c.getMacroIds(l.id)},rmscalebox:(t,e)=>E(t,e,"scalebox"),rmminiscale:(t,e)=>E(t,e,"miniscale")},$={align:"left",append:!1,cutlist:!0,dy:8,id:"title",force:!1,nr:1,rotation:0,scale:1,title:"plugin-annotations:noName",notes:!1,brand:"FreeSewing",classes:{notes:"text-md fill-current",date:"text-sm fill-current",name:"fill-note",nr:"text-4xl fill-note font-bold",title:"text-lg fill-current font-bold"}},L={title:function(t,{Point:e,points:n,scale:s,locale:o,store:r,part:i,log:a,complete:c}){if(!c&&!t.force)return;const l={...$,...t,classes:$.classes};t.classes&&(l.classes={...l.classes,...t.classes}),l.scale=l.scale*s,l.at&&"function"==typeof l.at.attr||(a.warn("Title macro called without a valid anchor point. Anchoring title at (0,0)."),l.at=new e(0,0)),["left","right","center"].includes(l.align)||(a.warn(`Title macro called with invali
1d alignement (${l.align}). Left-aligning title.`),l.align="left");const h=`matrix(${l.scale}, 0, 0, ${l.scale}, `+(l.at.x-l.scale*l.at.x)+", "+(l.at.y-l.scale*l.at.y)+`) rotate(${l.rotation} ${l.at.x} ${l.at.y})`,p=r.generateMacroIds(["nr","date","title","name","notes"],l.id);let d=l.dy;void 0!==l.nr?(n[p.nr]=l.at.clone().attr("data-text",l.nr,!l.append).attr("data-text-class",`${l.classes.nr} ${l.align}`).attr("data-text-transform",h).attr("data-render-always",1),r.set(["partNumbers",i.name],l.nr)):delete p.nr,n[p.date]=l.at.shift(-90,d/2).addText((new Date).toLocaleString(o||"en",{weekday:"long",year:"numeric",month:"short",day:"numeric"}),`${l.classes.date} ${l.align}`).attr("data-text-transform",h).attr("data-render-always",1),d+=l.dy,l.title?(n[p.title]=l.at.clone().shift(-90,d).attr("data-text-transform",h).attr("data-render-always",1),l.append?n[p.title].addText(l.title,`${l.classes.title} ${l.align}`):n[p.title].setText(l.title,`${l.classes.title} ${l.align}`),d+=l.dy,r.set(["partTitles",i.name],l.title)):delete p.title;const u=i.context.settings;var m;n[p.name]=l.at.clone().shift(-90,d).addText(`${l.brand} ${m=(r.data?.name||"plugin-annotations:noName").replace("@freesewing/",""),"string"==typeof m?m.charAt(0).toUpperCase()+m.slice(1):""} v${r.data?.version||"plugin-annotations:noVersion"} (`,`${l.classes.name} ${l.align}`).addText(u.metadata?.setName?u.metadata.setName:"ephemeral").addText(")").attr("data-text-transform",h).attr("data-render-always",1),d+=l.dy;const f=[];if(l.cutlist){n[p.notes]=l.at.clone().shift(-90,d);const t=r.get(["cutlist",i.name],null);if(t?.materials)for(const[e,n]of Object.entries(t.materials))n.forEach((({cut:t,identical:n,onBias:s,onFold:o})=>{f.push("plugin-annotations:cut"),f.push(t),!n&&t>1&&f.push("plugin-annotations:mirrored"),o?f.push(s?"plugin-annotations:onFoldAndBias":"plugin-annotations:onFold"):s&&f.push("plugin-annotations:onBias"),f.push("plugin-annotations:from",(e.includes(":")?"":"plugin-annotations:")+e),f.push("\n")}))}return l.notes&&(Array.isArray(l.notes)?f.push(...l.notes):f.push(l.notes)),f.length>0?n[p.notes].addText(f,`${l.classes.notes} ${l.align}`).attr("data-text-transform",h).attr("data-render-always",1).attr("data-text-lineheight",l.dy):delete p.cutlist,r.storeMacroIds(l.id,{points:p}),r.getMacroIds(l.id)},rmtitle:(t=$.id,{store:e,part:n})=>e.removeMacroNodes(t,"title",n)},C={classes:{line:"note",text:"center fill-note"},id:"cutonfold",grainline:!1,margin:.05,offset:15,reverse:!1},S=[{name:"cutonfoldFrom",def:t=>`\n<marker orient="auto" refY="0" refX="0" id="cutonfoldFrom" style="overflow:visible;" markerWidth="12" markerHeight="8" transform="scale(${t})">\n\t<path class="note fill-note" d="M 0,0 L 12,-4 C 10,-2 10,2 12,4 z" transform="scale(${t})"/>\n</marker>`},{name:"cutonfoldTo",def:t=>`\n<marker orient="auto" refY="0" refX="0" id="cutonfoldTo" style="overflow:visible;" markerWidth="12" markerHeight="8" transform="scale(${t})">\n\t<path class="note fill-note" d="M 0,0 L -12,-4 C -10,-2 -10,2 -12,4 z" transform="scale(${t})"/>\n</marker>`}],N={cutonfold:function(t,{paths:e,Path:n,complete:s,store:o,scale:r,log:i,Point:a}){if(!s&&!t.force)return;const c={...C,text:t.grainline?"plugin-annotations:cutOnFoldAndGrainline":"plugin-annotations:cutOnFold",...t,classes:C.classes};t.classes&&(c.classes={...c.classes,...t.classes}),c.from&&"function"==typeof c.from.attr||(i.warn("Cutonfold macro called without a valid from point. Using (0,0) for from."),c.from=new a(0,0)),c.to&&"function"==typeof c.to.attr||(i.warn("Cutonfold macro called without a valid to point. Using (6660,666) for to."),c.to=new a(666,666)),o.cutlist.setCutOnFold(c.from,c.to),c.grainline&&o.cutlist.setGrain(c.from.angle(c.to),"cutonfold");const l=o.generateMacroIds(["line"],c.id),h=c.from.shiftFractionTowards(c.to,c.margin),p=c.to.shiftFractionTowards(c.from,c.margin),d=h.shiftTowards(c.from,c.offset*r).rotate(-90,h),u=p.shiftTowards(c.to,c.offset*r).rotate(90,p);return e[l.line]=(new n).move(h).line(d).line(u).line(p),c.reverse&&(e[l.line]=e[l.line].reverse()),e[l.line]=e[l.line].attr("class",c.classes.line).attr("marker-start","url(#cutonfoldFrom)").attr("marker-end","url(#cutonfoldTo)").addText(c.text,c.classes.text),o.storeMacroIds(c.id,{paths:l}),o.getMacroIds(c.id)},rmcutonfold:(t=C.id,{store:e,part:n})=>("cutonfold"===e.cutlist.getGrainOrigin()&&e.cutlist.removeGrain(),e.cutlist.removeCutOnFold(),e.removeMacroNodes(t,"cutonfold",n))},A=[{name:"dimensionFrom",def:t=>`\n<marker orient="auto" refY="0" refX="0" id="dimensionFrom" style="overflow:visible;" markerWidth="12" markerHeight="8">\n\t<path class="mark fill-mark" d="M 0,0 L 12,-4 C 10,-2 10,2 12,4 z" transform="scale(${t})"/>\n</marker>`},{name:"dimensionTo",def:t=>`\n<marker orient="auto" refY="0" refX="0" id="dimensionTo" style="overflow:visible;" markerWidth="12" markerHeight="8">\n\t<path class="mark fill-mark" d="M 0,0 L -12,-4 C -10,-2 -10,2 -12,4 z" transform="scale(${t})"/>\n</marker>`}],O={text:!1,noStartMarker:!1,noEndMarker:!1,classes:{line:"mark",leaders:"mark dotted",text:"fill-mark center"}},R={hd:function(t,e,n,s){let o;return void 0===t.y||t[e].y===t.y?o=t[e]:(o=new n.Point(t[e].x,t.y),j(n,t[e],o,s)),o},vd:function(t,e,n,s){let o;return void 0===t.x||t[e].x===t.x?o=t[e]:(o=new n.Point(t.x,t[e].y),j(n,t[e],o,s)),o},ld:function(t,e,n,s){let o,r,i;return"from"===e?(r=1,i="to"):(r=-1,i="from"),void 0===t.d?o=t[e]:(o=t[e].shiftTowards(t[i],t.d).rotate(90*r,t[e]),j(n,t[e],o,s)),o}};function j({paths:t,Path:e},n,s,o){t[o]=(new e).move(n).line(s).attr("class","mark dotted")}const I=(t,e,n)=>{if(!e.paperless&&!t.force)return;const s={...O[n],id:n,...t,classes:O.classes};t.classes&&(s.classes={...s.classes,...t.classes});const o=e.store.generateMacroIds(["line","from","to"],s.id);return"pd"===n?(void 0===s.d&&(s.d=10*e.scale),e.paths[o.line]=s.path.offset(s.d).attr("class",s.classes.line).addText(s.text||e.units(s.path.length()),s.classes.text),s.noStartMarker||e.paths[o.line].attributes.set("marker-start","url(#dimensionFrom)"),s.noEndMarker||e.paths[o.line].attributes.set("marker-end","url(#dimensionTo)"),j(e,s.path.start(),e.paths[o.line].start(),o.from),j(e,s.path.end(),e.paths[o.line].end(),o.to)):e.paths[o.line]=function(t,e,n,{Path:s,units:o}){const r=(new s).move(t).line(e).attr("class","mark").attr("data-text",n.text||o(t.dist(e))).attr("data-text-class","fill-mark center").attr("data-macro-id",n.id);return n.noStartMarker||r.attributes.set("marker-start","url(#dimensionFrom)"),n.noEndMarker||r.attributes.set("marker-end","url(#dimensionTo)"),r}(R[n](s,"from",e,o.from),R[n](s,"to",e,o.to),s,e),e.store.storeMacroIds(s.id,{paths:o}),e.store.getMacroIds(s.id)},T=function(t=O.id,{store:e,part:n},s){return e.removeMacroNodes(t,s,n)},z=function({store:t,part:e},n){const s=t.get(["parts",e.name,"macros",n,"ids"],{});for(const o in s)t.removeMacroNodes(o,n,e)},H={hd:(t,e)=>I(t,e,"hd"),ld:(t,e)=>I(t,e,"ld"),vd:(t,e)=>I(t,e,"vd"),pd:(t,e)=>I(t,e,"pd"),rmhd:(t,e)=>T(t,e,"hd"),rmld:(t,e)=>T(t,e,"ld"),rmvd:(t,e)=>T(t,e,"vd"),rmpd:(t,e)=>T(t,e,"pd"),rmahd:(t,e)=>z(e,"hd"),rmald:(t,e)=>z(e,"ld"),rmavd:(t,e)=>z(e,"vd"),rmapd:(t,e)=>z(e,"pd"),rmad:(t,e)=>function({macro:t}){t("rmahd"),t("rmald"),t("rmavd"),t("rmapd")}(e)},F={classes:{line:"note",text:"center fill-note"},id:"grainline",margin:.05,text:"plugin-annotations:grainline"},V=[{name:"grainlineFrom",def:t=>`\n<marker orient="auto" refY="0" refX="0" id="grainlineFrom" style="overflow:visible;" markerWidth="12" markerHeight="8">\n\t<path class="note fill-note" d="M -10,0 L 2,-4 C 0,-2 0,2 2,4 z" transform="scale(${t})"/>\n</marker>`},{name:"grainlineTo",def:t=>`\n<marker orient="auto" refY="0" refX="0" id="grainlineTo" style="overflow:visible;" markerWidth="12" markerHeight="8">\n\t<path class="note fill-note" d="M 10,0 L -2,-4 C 0,-2 -2,2 -2,4 z" transform="scale(${t})"/>\n</marker>`}],D={grainline:function(t={},{paths:e,Path:n,Point:s,complete:o,store:r,log:i}){if(!o&&!t.force)return;const a={...F,...t,classes:F.classes};t.classes&&(a.classes={...a.classes,...t.classes}),a.from&&"function"==typeof a.from.attr||(i.warn("Grainline macro called without a valid from point. Using (0,0) for from."),a.from=new s(0,0)),a.to&&"function"==typeof a.to.attr||(i.warn("Grainline macro called without a valid to point. Using (666,666) for to."),a.to=new s(666,666)),r.cutlist.setGrain(a.from.angle(a.to),"grainline");const c=r.generateMacroIds(["line"],a.id),l=a.from.shiftFractionTowards(a.to,.05),h=a.to.shiftFractionTowards(a.from,.05);return e[c.line]=(new n).move(l).line(h).attr("class",a.classes.line).attr("marker-start","url(#grainlineFrom)").attr("marker-end","url(#grainlineTo)").addText(a.text,a.classes.text),r.storeMacroIds(a.id,{paths:c}),r.getMacroIds(a.id)},rmgrainline:(t=F.id,{store:e,part:n})=>("grainline"===e.cutlist.getGrainOrigin()&&e.cutlist.removeGrain(),e.removeMacroNodes(t,"grainline",n))},U={classes:{arrow:"note",from:"note",to:"note dashed"},id:"pleat",margin:35,reverse:!1},B=[{name:"pleat",def:t=>`\n<marker id="pleatTo" markerWidth="10" markerHeight="6" orient="auto" refY="3" refX="10">\n\t<path d="M 10,3 L 0,0 C 2,2 2,4 0,6 z" class="fill-note note" transform="scale(${t})" />\n</marker>\n`}],W={pleat:function(t,{paths:e,Path:n,log:s,Point:o,complete:r,scale:i,store:a}){if(!r&&!t.force)return;
1const c={...U,...t,classes:U.classes};t.classes&&(c.classes={...c.classes,...t.classes}),c.from&&"function"==typeof c.from.attr||(s.warn("Pleat macro called without a valid from point. Using (0,0) for from."),c.from=new o(0,0)),c.to&&"function"==typeof c.to.attr||(s.warn("Pleat macro called without a valid to point. Using (666,666) for to."),c.to=new o(666,666));const l=a.generateMacroIds(["from","to","arrow"],c.id),h=c.to.shift(c.from.shiftTowards(c.to,.1).angle(c.to)+90,c.margin*i),p=c.from.shift(c.from.shiftTowards(c.to,.1).angle(c.from)+270,c.margin*i);return e[l.from]=(new n).move(c.from).line(p).attr("class",c.reverse?c.classes.to:c.classes.from),e[l.to]=(new n).move(c.to).line(h).attr("class",c.reverse?c.classes.from:c.classes.to),e[l.arrow]=c.reverse?(new n).move(c.to.shiftFractionTowards(h,.25)).line(c.from.shiftFractionTowards(h,.25)):(new n).move(c.from.shiftFractionTowards(p,.25)).line(c.to.shiftFractionTowards(p,.25)),e[l.arrow].attr("class",c.classes.arrow).attr("marker-end","url(#pleatTo)"),a.storeMacroIds(c.id,{paths:l}),a.getMacroIds(c.id)},rmpleat:(t=U.id,{store:e,part:n})=>e.removeMacroNodes(t,"rmpleat",n)},G={classes:{curve:"dotted note stroke-sm",hinge:"note dotted stroke-sm",text:"center fill-note text-xs"},id:"sewtogether",force:!1,text:"plugin-annotations:sewTogether"},Z=[{name:"sewTogetherStart",def:t=>`\n<marker id="sewTogetherStart" markerWidth="10" markerHeight="6" orient="auto" refX="1" refY="2">\n\t<path d="M 0,2 L 6,0 C 5,1 5,3 6,4 z" class="fill-note note" transform="scale(${t})" />\n</marker>`},{name:"sewTogetherEnd",def:t=>`\n<marker id="sewTogetherEnd" markerWidth="10" markerHeight="6" orient="auto" refX="6" refY="2">\n\t<path d="M 6,2 L 0,0 C 1,1 1,3 0,4 z" class="fill-note note" transform="scale(${t})" />\n</marker>`},{name:"sewTogetherCross",def:t=>`\n<marker id="sewTogetherCross" markerWidth="5" markerHeight="5" orient="auto" refX="2.5" refY="2.5">\n <path d="M 0,0 L 5,5 M 5,0 L 0,5" class="note" transform="scale(${t})" />\n</marker>`}],Y={sewtogether:function(t,{paths:e,Path:n,log:s,Point:o,complete:r,sa:i,store:a}){if(!r&&!t.force)return;const c={...G,...t,classes:G.classes};t.classes&&(c.classes={...c.classes,...t.classes}),c.from&&"function"==typeof c.from.attr||(s.warn("Sewtogether macro called without a valid from point. Using (0,0) for from."),c.from=new o(0,0)),c.to&&"function"==typeof c.to.attr||(s.warn("Sewtogether macro called without a valid to point. Using (666,666) for to."),c.to=new o(666,666)),c.middle||(c.middle=c.from.shiftFractionTowards(c.to,.5));const l=a.generateMacroIds(["curve","hinge"],c.id),h=c.from.shift(c.from.angle(c.middle)+90,c.from.dist(c.middle)/1.5),p=c.to.shift(c.to.angle(c.middle)-90,c.to.dist(c.middle)/1.5);if(e[l.curve]=(new n).move(c.from).curve(h,p,c.to).attr("class",c.classes.curve).attr("marker-start","url(#sewTogetherStart)").attr("marker-end","url(#sewTogetherEnd)").addText(c.text,c.classes.text),c.hinge){const t=c.middle.shift(c.middle.angle(c.to)+Math.abs(c.middle.angle(c.from)-c.middle.angle(c.to))/2+(i?180:0),i||c.from.dist(c.middle)/4);e[l.hinge]=(new n).move(c.middle).line(t).attr("marker-start","url(#sewTogetherCross)").attr("class",c.classes.hinge)}else delete l.hinge;return a.storeMacroIds(c.id,{paths:l}),a.getMacroIds(c.id)},rmsewtogether:(t=G.id,{store:e,part:n})=>e.removeMacroNodes(t,"sewtogether",n)},J=["plugins","plugin-annotations","flags"],q=[["flag.info",(t,e)=>X("info",t,e)],["flag.tip",(t,e)=>X("tip",t,e)],["flag.note",(t,e)=>X("note",t,e)],["flag.warn",(t,e)=>X("warn",t,e)],["flag.fixme",(t,e)=>X("fixme",t,e)],["flag.error",(t,e)=>X("error",t,e)],["flag.preset",(t,e)=>X("preset",t,e)],["unflag.info",(t,e)=>K("info",t,e)],["unflag.tip",(t,e)=>K("tip",t,e)],["unflag.note",(t,e)=>K("note",t,e)],["unflag.warn",(t,e)=>K("warn",t,e)],["unflag.fixme",(t,e)=>K("fixme",t,e)],["unflag.error",(t,e)=>K("error",t,e)],["unflag.preset",(t,e)=>K("preset",t,e)]];function X(t,e,n){"preset"===t&&Q[n]&&(t=(n=Q[n]).type),n.msg&&(n.title=n.msg+".t",n.desc=n.msg+".d",delete n.msg),n.id||n.title?e.set([...J,t,n.id?n.id:n.title],n):e.log.warn(`store.flag.${t} called without an id or title property`)}function K(t,e,n){"preset"===t&&Q[n]&&(t=Q[n].type,n=Q[n].id||Q[n].title),e.unset([...J,t,n])}const Q={expandIsOff:{type:"tip",title:"flag:expandIsOff.t",desc:"flag:expandIsOff.d",suggest:{text:"flag:enable",icon:"expand",update:{settings:["expand",1]}}},expandIsOn:{type:"tip",title:"flag:expandIsOn.t",desc:"flag:expandIsOn.d",suggest:{text:"flag:disable",icon:"compact",update:{settings:["expand",0]}}}},tt={name:s.id,version:s.r,hooks:{preRender:[function(t){const e=[...r,...S,...A,...V,...a,...c,...B,...Z];for(const n of e)t.defs.setIfUnset(n.name,"function"==typeof n.def?n.def(t.pattern.settings[0].scale):n.def)}],prePartDraft:[function(t){const e=t.config.inject[t.activePart];if(!e)return;const n=t.setStores[t.activeSet],s=n.get(["cutlist",e],{});n.set(["cutlist",t.activePart],{...s})}]},macros:{...h,...d,...y,...x,...P,...N,...H,...D,...W,...Y,...L},store:[...b,...q]},et=tt,nt=o}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.