designix-uis 0.5.19 → 0.5.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/designix-uis.js +1 -1
- package/dist/public/_app/immutable/chunks/{entry.CCZQw5oO.js → entry.BFaAd9jL.js} +1 -1
- package/dist/public/_app/immutable/chunks/{index.Bt0gWcKV.js → index.FRem4NB_.js} +1 -1
- package/dist/public/_app/immutable/chunks/{makeList.REsiyAUZ.js → makeList.D9WwT8E8.js} +1 -1
- package/dist/public/_app/immutable/chunks/paths.CmHCI0tQ.js +1 -0
- package/dist/public/_app/immutable/chunks/{stores.DWbCP-9J.js → stores.CNgkQH-j.js} +1 -1
- package/dist/public/_app/immutable/entry/{app.465Ho3ps.js → app.C6672aWl.js} +2 -2
- package/dist/public/_app/immutable/entry/start.DfzDaxWI.js +1 -0
- package/dist/public/_app/immutable/nodes/{0.DAExDjEC.js → 0.CsAWk4mK.js} +1 -1
- package/dist/public/_app/immutable/nodes/{1.CGoocqNb.js → 1.DDwhwPCl.js} +1 -1
- package/dist/public/_app/immutable/nodes/{2.hzTdm1WZ.js → 2.1cPiKGbF.js} +1 -1
- package/dist/public/_app/immutable/nodes/{3.R7r_9i1-.js → 3.BlyuNevc.js} +1 -1
- package/dist/public/_app/version.json +1 -1
- package/dist/public/gear/gear_wheel_wheel.html +13 -13
- package/dist/public/gear/simplified_gear_wheel.html +13 -13
- package/dist/public/heliostat/base.html +13 -13
- package/dist/public/heliostat/haxis_guidance.html +13 -13
- package/dist/public/heliostat/heliostat.html +13 -13
- package/dist/public/heliostat/heliostat_2.html +13 -13
- package/dist/public/heliostat/pole_static.html +13 -13
- package/dist/public/heliostat/rake.html +13 -13
- package/dist/public/heliostat/rake_stopper.html +13 -13
- package/dist/public/heliostat/ring.html +13 -13
- package/dist/public/heliostat/ring_guidance.html +13 -13
- package/dist/public/heliostat/rod.html +13 -13
- package/dist/public/heliostat/spider.html +13 -13
- package/dist/public/heliostat/surface.html +13 -13
- package/dist/public/heliostat/swing.html +13 -13
- package/dist/public/heliostat/trapeze.html +13 -13
- package/dist/public/heliostat/vaxis.html +13 -13
- package/dist/public/heliostat/vaxis_guidance.html +13 -13
- package/dist/public/heliostat/vaxis_holder.html +13 -13
- package/dist/public/index.html +11 -11
- package/package.json +1 -1
- package/dist/public/_app/immutable/chunks/paths.BE-8toip.js +0 -1
- package/dist/public/_app/immutable/entry/start.Dapam0r7.js +0 -1
package/dist/designix-uis.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{n as lt,s as ie,x as ce}from"./scheduler.2BOoCPD3.js";import{a as le,b as P}from"./paths.BE-8toip.js";new URL("sveltekit-internal://");function fe(t,n){return t==="/"||n==="ignore"?t:n==="never"?t.endsWith("/")?t.slice(0,-1):t:n==="always"&&!t.endsWith("/")?t+"/":t}function ue(t){return t.split("%25").map(decodeURI).join("%25")}function de(t){for(const n in t)t[n]=decodeURIComponent(t[n]);return t}function ft({href:t}){return t.split("#")[0]}const he=["href","pathname","search","toString","toJSON"];function pe(t,n,e){const a=new URL(t);Object.defineProperty(a,"searchParams",{value:new Proxy(a.searchParams,{get(r,o){if(o==="get"||o==="getAll"||o==="has")return s=>(e(s),r[o](s));n();const i=Reflect.get(r,o);return typeof i=="function"?i.bind(r):i}}),enumerable:!0,configurable:!0});for(const r of he)Object.defineProperty(a,r,{get(){return n(),t[r]},enumerable:!0,configurable:!0});return a}const ge="/__data.json",me=".html__data.json";function _e(t){return t.endsWith(".html")?t.replace(/\.html$/,me):t.replace(/\/$/,"")+ge}function ye(...t){let n=5381;for(const e of t)if(typeof e=="string"){let a=e.length;for(;a;)n=n*33^e.charCodeAt(--a)}else if(ArrayBuffer.isView(e)){const a=new Uint8Array(e.buffer,e.byteOffset,e.byteLength);let r=a.length;for(;r;)n=n*33^a[--r]}else throw new TypeError("value must be a string or TypedArray");return(n>>>0).toString(36)}function we(t){const n=atob(t),e=new Uint8Array(n.length);for(let a=0;a<n.length;a++)e[a]=n.charCodeAt(a);return e.buffer}const Dt=window.fetch;window.fetch=(t,n)=>((t instanceof Request?t.method:(n==null?void 0:n.method)||"GET")!=="GET"&&G.delete(mt(t)),Dt(t,n));const G=new Map;function ve(t,n){const e=mt(t,n),a=document.querySelector(e);if(a!=null&&a.textContent){let{body:r,...o}=JSON.parse(a.textContent);const i=a.getAttribute("data-ttl");return i&&G.set(e,{body:r,init:o,ttl:1e3*Number(i)}),a.getAttribute("data-b64")!==null&&(r=we(r)),Promise.resolve(new Response(r,o))}return window.fetch(t,n)}function be(t,n,e){if(G.size>0){const a=mt(t,e),r=G.get(a);if(r){if(performance.now()<r.ttl&&["default","force-cache","only-if-cached",void 0].includes(e==null?void 0:e.cache))return new Response(r.body,r.init);G.delete(a)}}return window.fetch(n,e)}function mt(t,n){let a=`script[data-sveltekit-fetched][data-url=${JSON.stringify(t instanceof Request?t.url:t)}]`;if(n!=null&&n.headers||n!=null&&n.body){const r=[];n.headers&&r.push([...new Headers(n.headers)].join(",")),n.body&&(typeof n.body=="string"||ArrayBuffer.isView(n.body))&&r.push(n.body),a+=`[data-hash="${ye(...r)}"]`}return a}const Ee=/^(\[)?(\.\.\.)?(\w+)(?:=(\w+))?(\])?$/;function ke(t){const n=[];return{pattern:t==="/"?/^\/$/:new RegExp(`^${Ae(t).map(a=>{const r=/^\[\.\.\.(\w+)(?:=(\w+))?\]$/.exec(a);if(r)return n.push({name:r[1],matcher:r[2],optional:!1,rest:!0,chained:!0}),"(?:/(.*))?";const o=/^\[\[(\w+)(?:=(\w+))?\]\]$/.exec(a);if(o)return n.push({name:o[1],matcher:o[2],optional:!0,rest:!1,chained:!0}),"(?:/([^/]+))?";if(!a)return;const i=a.split(/\[(.+?)\](?!\])/);return"/"+i.map((c,l)=>{if(l%2){if(c.startsWith("x+"))return ut(String.fromCharCode(parseInt(c.slice(2),16)));if(c.startsWith("u+"))return ut(String.fromCharCode(...c.slice(2).split("-").map(f=>parseInt(f,16))));const u=Ee.exec(c),[,h,g,d,_]=u;return n.push({name:d,matcher:_,optional:!!h,rest:!!g,chained:g?l===1&&i[0]==="":!1}),g?"(.*?)":h?"([^/]*)?":"([^/]+?)"}return ut(c)}).join("")}).join("")}/?$`),params:n}}function Se(t){return!/^\([^)]+\)$/.test(t)}function Ae(t){return t.slice(1).split("/").filter(Se)}function Re(t,n,e){const a={},r=t.slice(1),o=r.filter(s=>s!==void 0);let i=0;for(let s=0;s<n.length;s+=1){const c=n[s];let l=r[s-i];if(c.chained&&c.rest&&i&&(l=r.slice(s-i,s+1).filter(u=>u).join("/"),i=0),l===void 0){c.rest&&(a[c.name]="");continue}if(!c.matcher||e[c.matcher](l)){a[c.name]=l;const u=n[s+1],h=r[s+1];u&&!u.rest&&u.optional&&h&&c.chained&&(i=0),!u&&!h&&Object.keys(a).length===o.length&&(i=0);continue}if(c.optional&&c.chained){i++;continue}return}if(!i)return a}function ut(t){return t.normalize().replace(/[[\]]/g,"\\$&").replace(/%/g,"%25").replace(/\//g,"%2[Ff]").replace(/\?/g,"%3[Ff]").replace(/#/g,"%23").replace(/[.*+?^${}()|\\]/g,"\\$&")}function Ie({nodes:t,server_loads:n,dictionary:e,matchers:a}){const r=new Set(n);return Object.entries(e).map(([s,[c,l,u]])=>{const{pattern:h,params:g}=ke(s),d={id:s,exec:_=>{const f=h.exec(_);if(f)return Re(f,g,a)},errors:[1,...u||[]].map(_=>t[_]),layouts:[0,...l||[]].map(i),leaf:o(c)};return d.errors.length=d.layouts.length=Math.max(d.errors.length,d.layouts.length),d});function o(s){const c=s<0;return c&&(s=~s),[c,t[s]]}function i(s){return s===void 0?s:[r.has(s),t[s]]}}function Ct(t,n=JSON.parse){try{return n(sessionStorage[t])}catch{}}function Pt(t,n,e=JSON.stringify){const a=e(n);try{sessionStorage[t]=a}catch{}}const O=[];function _t(t,n=lt){let e;const a=new Set;function r(s){if(ie(t,s)&&(t=s,e)){const c=!O.length;for(const l of a)l[1](),O.push(l,t);if(c){for(let l=0;l<O.length;l+=2)O[l][0](O[l+1]);O.length=0}}}function o(s){r(s(t))}function i(s,c=lt){const l=[s,c];return a.add(l),a.size===1&&(e=n(r,o)||lt),s(t),()=>{a.delete(l),a.size===0&&e&&(e(),e=null)}}return{set:r,update:o,subscribe:i}}const Le="1715264384742",Vt="sveltekit:snapshot",Ft="sveltekit:scroll",qt="sveltekit:states",Pe="sveltekit:pageurl",D="sveltekit:history",M="sveltekit:navigation",J={tap:1,hover:2,viewport:3,eager:4,off:-1,false:-1},z=location.origin;function Gt(t){if(t instanceof URL)return t;let n=document.baseURI;if(!n){const e=document.getElementsByTagName("base");n=e.length?e[0].href:document.URL}return new URL(t,n)}function yt(){return{x:pageXOffset,y:pageYOffset}}function j(t,n){return t.getAttribute(`data-sveltekit-${n}`)}const xt={...J,"":J.hover};function Ht(t){let n=t.assignedSlot??t.parentNode;return(n==null?void 0:n.nodeType)===11&&(n=n.host),n}function Mt(t,n){for(;t&&t!==n;){if(t.nodeName.toUpperCase()==="A"&&t.hasAttribute("href"))return t;t=Ht(t)}}function ht(t,n){let e;try{e=new URL(t instanceof SVGAElement?t.href.baseVal:t.href,document.baseURI)}catch{}const a=t instanceof SVGAElement?t.target.baseVal:t.target,r=!e||!!a||at(e,n)||(t.getAttribute("rel")||"").split(/\s+/).includes("external"),o=(e==null?void 0:e.origin)===z&&t.hasAttribute("download");return{url:e,external:r,target:a,download:o}}function W(t){let n=null,e=null,a=null,r=null,o=null,i=null,s=t;for(;s&&s!==document.documentElement;)a===null&&(a=j(s,"preload-code")),r===null&&(r=j(s,"preload-data")),n===null&&(n=j(s,"keepfocus")),e===null&&(e=j(s,"noscroll")),o===null&&(o=j(s,"reload")),i===null&&(i=j(s,"replacestate")),s=Ht(s);function c(l){switch(l){case"":case"true":return!0;case"off":case"false":return!1;default:return}}return{preload_code:xt[a??"off"],preload_data:xt[r??"off"],keepfocus:c(n),noscroll:c(e),reload:c(o),replace_state:c(i)}}function Ut(t){const n=_t(t);let e=!0;function a(){e=!0,n.update(i=>i)}function r(i){e=!1,n.set(i)}function o(i){let s;return n.subscribe(c=>{(s===void 0||e&&c!==s)&&i(s=c)})}return{notify:a,set:r,subscribe:o}}function xe(){const{set:t,subscribe:n}=_t(!1);let e;async function a(){clearTimeout(e);try{const r=await fetch(`${le}/_app/version.json`,{headers:{pragma:"no-cache","cache-control":"no-cache"}});if(!r.ok)return!1;const i=(await r.json()).version!==Le;return i&&(t(!0),clearTimeout(e)),i}catch{return!1}}return{subscribe:n,check:a}}function at(t,n){return t.origin!==z||!t.pathname.startsWith(n)}const Ue=-1,Te=-2,Ne=-3,Oe=-4,je=-5,$e=-6;function De(t,n){if(typeof t=="number")return r(t,!0);if(!Array.isArray(t)||t.length===0)throw new Error("Invalid input");const e=t,a=Array(e.length);function r(o,i=!1){if(o===Ue)return;if(o===Ne)return NaN;if(o===Oe)return 1/0;if(o===je)return-1/0;if(o===$e)return-0;if(i)throw new Error("Invalid input");if(o in a)return a[o];const s=e[o];if(!s||typeof s!="object")a[o]=s;else if(Array.isArray(s))if(typeof s[0]=="string"){const c=s[0],l=n==null?void 0:n[c];if(l)return a[o]=l(r(s[1]));switch(c){case"Date":a[o]=new Date(s[1]);break;case"Set":const u=new Set;a[o]=u;for(let d=1;d<s.length;d+=1)u.add(r(s[d]));break;case"Map":const h=new Map;a[o]=h;for(let d=1;d<s.length;d+=2)h.set(r(s[d]),r(s[d+1]));break;case"RegExp":a[o]=new RegExp(s[1],s[2]);break;case"Object":a[o]=Object(s[1]);break;case"BigInt":a[o]=BigInt(s[1]);break;case"null":const g=Object.create(null);a[o]=g;for(let d=1;d<s.length;d+=2)g[s[d]]=r(s[d+1]);break;default:throw new Error(`Unknown type ${c}`)}}else{const c=new Array(s.length);a[o]=c;for(let l=0;l<s.length;l+=1){const u=s[l];u!==Te&&(c[l]=r(u))}}else{const c={};a[o]=c;for(const l in s){const u=s[l];c[l]=r(u)}}return a[o]}return r(0)}const Bt=new Set(["load","prerender","csr","ssr","trailingSlash","config"]);[...Bt];const Ce=new Set([...Bt]);[...Ce];function Ve(t){return t.filter(n=>n!=null)}class rt{constructor(n,e){this.status=n,typeof e=="string"?this.body={message:e}:e?this.body=e:this.body={message:`Error: ${n}`}}toString(){return JSON.stringify(this.body)}}class Kt{constructor(n,e){this.status=n,this.location=e}}class wt extends Error{constructor(n,e,a){super(a),this.status=n,this.text=e}}const Fe="x-sveltekit-invalidated",qe="x-sveltekit-trailing-slash";function X(t){return t instanceof rt||t instanceof wt?t.status:500}function Ge(t){return t instanceof wt?t.text:"Internal Error"}const N=Ct(Ft)??{},B=Ct(Vt)??{},U={url:Ut({}),page:Ut({}),navigating:_t(null),updated:xe()};function vt(t){N[t]=yt()}function He(t,n){let e=t+1;for(;N[e];)delete N[e],e+=1;for(e=n+1;B[e];)delete B[e],e+=1}function V(t){return location.href=t.href,new Promise(()=>{})}function Tt(){}let ot,pt,Z,x,gt,F;const zt=[],Q=[];let R=null;const Yt=[],Me=[];let $=[],y={branch:[],error:null,url:null},bt=!1,tt=!1,Nt=!0,K=!1,q=!1,Jt=!1,Et=!1,kt,S,L,I,et;const H=new Set;async function nn(t,n,e){var r,o;document.URL!==location.href&&(location.href=location.href),F=t,ot=Ie(t),x=document.documentElement,gt=n,pt=t.nodes[0],Z=t.nodes[1],pt(),Z(),S=(r=history.state)==null?void 0:r[D],L=(o=history.state)==null?void 0:o[M],S||(S=L=Date.now(),history.replaceState({...history.state,[D]:S,[M]:L},""));const a=N[S];a&&(history.scrollRestoration="manual",scrollTo(a.x,a.y)),e?await Ze(gt,e):We(location.href,{replaceState:!0}),Xe()}function Be(){zt.length=0,Et=!1}function Wt(t){Q.some(n=>n==null?void 0:n.snapshot)&&(B[t]=Q.map(n=>{var e;return(e=n==null?void 0:n.snapshot)==null?void 0:e.capture()}))}function Xt(t){var n;(n=B[t])==null||n.forEach((e,a)=>{var r,o;(o=(r=Q[a])==null?void 0:r.snapshot)==null||o.restore(e)})}function Ot(){vt(S),Pt(Ft,N),Wt(L),Pt(Vt,B)}async function Zt(t,n,e,a){return Y({type:"goto",url:Gt(t),keepfocus:n.keepFocus,noscroll:n.noScroll,replace_state:n.replaceState,state:n.state,redirect_count:e,nav_token:a,accept:()=>{n.invalidateAll&&(Et=!0)}})}async function Ke(t){if(t.id!==(R==null?void 0:R.id)){const n={};H.add(n),R={id:t.id,token:n,promise:te({...t,preload:n}).then(e=>(H.delete(n),e.type==="loaded"&&e.state.error&&(R=null),e))}}return R.promise}async function dt(t){const n=ot.find(e=>e.exec(ee(t)));n&&await Promise.all([...n.layouts,n.leaf].map(e=>e==null?void 0:e[1]()))}function Qt(t,n,e){var o;y=t.state;const a=document.querySelector("style[data-sveltekit]");a&&a.remove(),I=t.props.page,kt=new F.root({target:n,props:{...t.props,stores:U,components:Q},hydrate:e}),Xt(L);const r={from:null,to:{params:y.params,route:{id:((o=y.route)==null?void 0:o.id)??null},url:new URL(location.href)},willUnload:!1,type:"enter",complete:Promise.resolve()};$.forEach(i=>i(r)),tt=!0}async function nt({url:t,params:n,branch:e,status:a,error:r,route:o,form:i}){let s="never";if(P&&(t.pathname===P||t.pathname===P+"/"))s="always";else for(const d of e)(d==null?void 0:d.slash)!==void 0&&(s=d.slash);t.pathname=fe(t.pathname,s),t.search=t.search;const c={type:"loaded",state:{url:t,params:n,branch:e,error:r,route:o},props:{constructors:Ve(e).map(d=>d.node.component),page:I}};i!==void 0&&(c.props.form=i);let l={},u=!I,h=0;for(let d=0;d<Math.max(e.length,y.branch.length);d+=1){const _=e[d],f=y.branch[d];(_==null?void 0:_.data)!==(f==null?void 0:f.data)&&(u=!0),_&&(l={...l,..._.data},u&&(c.props[`data_${h}`]=l),h+=1)}return(!y.url||t.href!==y.url.href||y.error!==r||i!==void 0&&i!==I.form||u)&&(c.props.page={error:r,params:n,route:{id:(o==null?void 0:o.id)??null},state:{},status:a,url:new URL(t),form:i??null,data:u?l:I.data}),c}async function St({loader:t,parent:n,url:e,params:a,route:r,server_data_node:o}){var u,h,g;let i=null,s=!0;const c={dependencies:new Set,params:new Set,parent:!1,route:!1,url:!1,search_params:new Set},l=await t();if((u=l.universal)!=null&&u.load){let d=function(...f){for(const m of f){const{href:b}=new URL(m,e);c.dependencies.add(b)}};const _={route:new Proxy(r,{get:(f,m)=>(s&&(c.route=!0),f[m])}),params:new Proxy(a,{get:(f,m)=>(s&&c.params.add(m),f[m])}),data:(o==null?void 0:o.data)??null,url:pe(e,()=>{s&&(c.url=!0)},f=>{s&&c.search_params.add(f)}),async fetch(f,m){let b;f instanceof Request?(b=f.url,m={body:f.method==="GET"||f.method==="HEAD"?void 0:await f.blob(),cache:f.cache,credentials:f.credentials,headers:f.headers,integrity:f.integrity,keepalive:f.keepalive,method:f.method,mode:f.mode,redirect:f.redirect,referrer:f.referrer,referrerPolicy:f.referrerPolicy,signal:f.signal,...m}):b=f;const A=new URL(b,e);return s&&d(A.href),A.origin===e.origin&&(b=A.href.slice(e.origin.length)),tt?be(b,A.href,m):ve(b,m)},setHeaders:()=>{},depends:d,parent(){return s&&(c.parent=!0),n()},untrack(f){s=!1;try{return f()}finally{s=!0}}};i=await l.universal.load.call(null,_)??null}return{node:l,loader:t,server:o,universal:(h=l.universal)!=null&&h.load?{type:"data",data:i,uses:c}:null,data:i??(o==null?void 0:o.data)??null,slash:((g=l.universal)==null?void 0:g.trailingSlash)??(o==null?void 0:o.slash)}}function jt(t,n,e,a,r,o){if(Et)return!0;if(!r)return!1;if(r.parent&&t||r.route&&n||r.url&&e)return!0;for(const i of r.search_params)if(a.has(i))return!0;for(const i of r.params)if(o[i]!==y.params[i])return!0;for(const i of r.dependencies)if(zt.some(s=>s(new URL(i))))return!0;return!1}function At(t,n){return(t==null?void 0:t.type)==="data"?t:(t==null?void 0:t.type)==="skip"?n??null:null}function ze(t,n){if(!t)return new Set(n.searchParams.keys());const e=new Set([...t.searchParams.keys(),...n.searchParams.keys()]);for(const a of e){const r=t.searchParams.getAll(a),o=n.searchParams.getAll(a);r.every(i=>o.includes(i))&&o.every(i=>r.includes(i))&&e.delete(a)}return e}function $t({error:t,url:n,route:e,params:a}){return{type:"loaded",state:{error:t,url:n,route:e,params:a,branch:[]},props:{page:I,constructors:[]}}}async function te({id:t,invalidating:n,url:e,params:a,route:r,preload:o}){if((R==null?void 0:R.id)===t)return H.delete(R.token),R.promise;const{errors:i,layouts:s,leaf:c}=r,l=[...s,c];i.forEach(p=>p==null?void 0:p().catch(()=>{})),l.forEach(p=>p==null?void 0:p[1]().catch(()=>{}));let u=null;const h=y.url?t!==y.url.pathname+y.url.search:!1,g=y.route?r.id!==y.route.id:!1,d=ze(y.url,e);let _=!1;const f=l.map((p,v)=>{var T;const E=y.branch[v],k=!!(p!=null&&p[0])&&((E==null?void 0:E.loader)!==p[1]||jt(_,g,h,d,(T=E.server)==null?void 0:T.uses,a));return k&&(_=!0),k});if(f.some(Boolean)){try{u=await re(e,f)}catch(p){const v=await C(p,{url:e,params:a,route:{id:t}});return H.has(o)?$t({error:v,url:e,params:a,route:r}):st({status:X(p),error:v,url:e,route:r})}if(u.type==="redirect")return u}const m=u==null?void 0:u.nodes;let b=!1;const A=l.map(async(p,v)=>{var it;if(!p)return;const E=y.branch[v],k=m==null?void 0:m[v];if((!k||k.type==="skip")&&p[1]===(E==null?void 0:E.loader)&&!jt(b,g,h,d,(it=E.universal)==null?void 0:it.uses,a))return E;if(b=!0,(k==null?void 0:k.type)==="error")throw k;return St({loader:p[1],url:e,params:a,route:r,parent:async()=>{var Lt;const It={};for(let ct=0;ct<v;ct+=1)Object.assign(It,(Lt=await A[ct])==null?void 0:Lt.data);return It},server_data_node:At(k===void 0&&p[0]?{type:"skip"}:k??null,p[0]?E==null?void 0:E.server:void 0)})});for(const p of A)p.catch(()=>{});const w=[];for(let p=0;p<l.length;p+=1)if(l[p])try{w.push(await A[p])}catch(v){if(v instanceof Kt)return{type:"redirect",location:v.location};if(H.has(o))return $t({error:await C(v,{params:a,url:e,route:{id:r.id}}),url:e,params:a,route:r});let E=X(v),k;if(m!=null&&m.includes(v))E=v.status??E,k=v.error;else if(v instanceof rt)k=v.body;else{if(await U.updated.check())return await V(e);k=await C(v,{params:a,url:e,route:{id:r.id}})}const T=await Ye(p,w,i);return T?await nt({url:e,params:a,branch:w.slice(0,T.idx).concat(T.node),status:E,error:k,route:r}):await ae(e,{id:r.id},k,E)}else w.push(void 0);return await nt({url:e,params:a,branch:w,status:200,error:null,route:r,form:n?void 0:null})}async function Ye(t,n,e){for(;t--;)if(e[t]){let a=t;for(;!n[a];)a-=1;try{return{idx:a+1,node:{node:await e[t](),loader:e[t],data:{},server:null,universal:null}}}catch{continue}}}async function st({status:t,error:n,url:e,route:a}){const r={};let o=null;if(F.server_loads[0]===0)try{const l=await re(e,[!0]);if(l.type!=="data"||l.nodes[0]&&l.nodes[0].type!=="data")throw 0;o=l.nodes[0]??null}catch{(e.origin!==z||e.pathname!==location.pathname||bt)&&await V(e)}const s=await St({loader:pt,url:e,params:r,route:a,parent:()=>Promise.resolve({}),server_data_node:At(o)}),c={node:await Z(),loader:Z,universal:null,server:null,data:null};return await nt({url:e,params:r,branch:[s,c],status:t,error:n,route:null})}function Rt(t,n){if(!t||at(t,P))return;let e;try{e=F.hooks.reroute({url:new URL(t)})??t.pathname}catch{return}const a=ee(e);for(const r of ot){const o=r.exec(a);if(o)return{id:t.pathname+t.search,invalidating:n,route:r,params:de(o),url:t}}}function ee(t){return ue(t.slice(P.length)||"/")}function ne({url:t,type:n,intent:e,delta:a}){let r=!1;const o=se(y,e,t,n);a!==void 0&&(o.navigation.delta=a);const i={...o.navigation,cancel:()=>{r=!0,o.reject(new Error("navigation cancelled"))}};return K||Yt.forEach(s=>s(i)),r?null:o}async function Y({type:t,url:n,popped:e,keepfocus:a,noscroll:r,replace_state:o,state:i={},redirect_count:s=0,nav_token:c={},accept:l=Tt,block:u=Tt}){const h=Rt(n,!1),g=ne({url:n,type:t,delta:e==null?void 0:e.delta,intent:h});if(!g){u();return}const d=S,_=L;l(),K=!0,tt&&U.navigating.set(g.navigation),et=c;let f=h&&await te(h);if(!f){if(at(n,P))return await V(n);f=await ae(n,{id:null},await C(new wt(404,"Not Found",`Not found: ${n.pathname}`),{url:n,params:{},route:{id:null}}),404)}if(n=(h==null?void 0:h.url)||n,et!==c)return g.reject(new Error("navigation aborted")),!1;if(f.type==="redirect")if(s>=20)f=await st({status:500,error:await C(new Error("Redirect loop"),{url:n,params:{},route:{id:null}}),url:n,route:{id:null}});else return Zt(new URL(f.location,n).href,{},s+1,c),!1;else f.props.page.status>=400&&await U.updated.check()&&await V(n);if(Be(),vt(d),Wt(_),f.props.page.url.pathname!==n.pathname&&(n.pathname=f.props.page.url.pathname),i=e?e.state:i,!e){const w=o?0:1,p={[D]:S+=w,[M]:L+=w,[qt]:i};(o?history.replaceState:history.pushState).call(history,p,"",n),o||He(S,L)}if(R=null,f.props.page.state=i,tt){y=f.state,f.props.page&&(f.props.page.url=n);const w=(await Promise.all(Me.map(p=>p(g.navigation)))).filter(p=>typeof p=="function");if(w.length>0){let p=function(){$=$.filter(v=>!w.includes(v))};w.push(p),$.push(...w)}kt.$set(f.props),Jt=!0}else Qt(f,gt,!1);const{activeElement:m}=document;await ce();const b=e?e.scroll:r?yt():null;if(Nt){const w=n.hash&&document.getElementById(decodeURIComponent(n.hash.slice(1)));b?scrollTo(b.x,b.y):w?w.scrollIntoView():scrollTo(0,0)}const A=document.activeElement!==m&&document.activeElement!==document.body;!a&&!A&&Qe(),Nt=!0,f.props.page&&(I=f.props.page),K=!1,t==="popstate"&&Xt(L),g.fulfil(void 0),$.forEach(w=>w(g.navigation)),U.navigating.set(null)}async function ae(t,n,e,a){return t.origin===z&&t.pathname===location.pathname&&!bt?await st({status:a,error:e,url:t,route:n}):await V(t)}function Je(){let t;x.addEventListener("mousemove",o=>{const i=o.target;clearTimeout(t),t=setTimeout(()=>{a(i,2)},20)});function n(o){a(o.composedPath()[0],1)}x.addEventListener("mousedown",n),x.addEventListener("touchstart",n,{passive:!0});const e=new IntersectionObserver(o=>{for(const i of o)i.isIntersecting&&(dt(i.target.href),e.unobserve(i.target))},{threshold:0});function a(o,i){const s=Mt(o,x);if(!s)return;const{url:c,external:l,download:u}=ht(s,P);if(l||u)return;const h=W(s);if(!h.reload)if(i<=h.preload_data){const g=Rt(c,!1);g&&Ke(g)}else i<=h.preload_code&&dt(c.pathname)}function r(){e.disconnect();for(const o of x.querySelectorAll("a")){const{url:i,external:s,download:c}=ht(o,P);if(s||c)continue;const l=W(o);l.reload||(l.preload_code===J.viewport&&e.observe(o),l.preload_code===J.eager&&dt(i.pathname))}}$.push(r),r()}function C(t,n){if(t instanceof rt)return t.body;const e=X(t),a=Ge(t);return F.hooks.handleError({error:t,event:n,status:e,message:a})??{message:a}}function We(t,n={}){return t=Gt(t),t.origin!==z?Promise.reject(new Error("goto: invalid URL")):Zt(t,n,0)}function Xe(){var n;history.scrollRestoration="manual",addEventListener("beforeunload",e=>{let a=!1;if(Ot(),!K){const r=se(y,void 0,null,"leave"),o={...r.navigation,cancel:()=>{a=!0,r.reject(new Error("navigation cancelled"))}};Yt.forEach(i=>i(o))}a?(e.preventDefault(),e.returnValue=""):history.scrollRestoration="auto"}),addEventListener("visibilitychange",()=>{document.visibilityState==="hidden"&&Ot()}),(n=navigator.connection)!=null&&n.saveData||Je(),x.addEventListener("click",e=>{var g;if(e.button||e.which!==1||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.defaultPrevented)return;const a=Mt(e.composedPath()[0],x);if(!a)return;const{url:r,external:o,target:i,download:s}=ht(a,P);if(!r)return;if(i==="_parent"||i==="_top"){if(window.parent!==window)return}else if(i&&i!=="_self")return;const c=W(a);if(!(a instanceof SVGAElement)&&r.protocol!==location.protocol&&!(r.protocol==="https:"||r.protocol==="http:")||s)return;if(o||c.reload){ne({url:r,type:"link"})?K=!0:e.preventDefault();return}const[u,h]=r.href.split("#");if(h!==void 0&&u===ft(location)){const[,d]=y.url.href.split("#");if(d===h){e.preventDefault(),h===""||h==="top"&&a.ownerDocument.getElementById("top")===null?window.scrollTo({top:0}):(g=a.ownerDocument.getElementById(h))==null||g.scrollIntoView();return}if(q=!0,vt(S),t(r),!c.replace_state)return;q=!1}e.preventDefault(),Y({type:"link",url:r,keepfocus:c.keepfocus,noscroll:c.noscroll,replace_state:c.replace_state??r.href===location.href})}),x.addEventListener("submit",e=>{if(e.defaultPrevented)return;const a=HTMLFormElement.prototype.cloneNode.call(e.target),r=e.submitter;if(((r==null?void 0:r.formMethod)||a.method)!=="get")return;const i=new URL((r==null?void 0:r.hasAttribute("formaction"))&&(r==null?void 0:r.formAction)||a.action);if(at(i,P))return;const s=e.target,c=W(s);if(c.reload)return;e.preventDefault(),e.stopPropagation();const l=new FormData(s),u=r==null?void 0:r.getAttribute("name");u&&l.append(u,(r==null?void 0:r.getAttribute("value"))??""),i.search=new URLSearchParams(l).toString(),Y({type:"form",url:i,keepfocus:c.keepfocus,noscroll:c.noscroll,replace_state:c.replace_state??i.href===location.href})}),addEventListener("popstate",async e=>{var a;if((a=e.state)!=null&&a[D]){const r=e.state[D];if(et={},r===S)return;const o=N[r],i=e.state[qt]??{},s=new URL(e.state[Pe]??location.href),c=e.state[M],l=ft(location)===ft(y.url);if(c===L&&(Jt||l)){t(s),N[S]=yt(),o&&scrollTo(o.x,o.y),i!==I.state&&(I={...I,state:i},kt.$set({page:I})),S=r;return}const h=r-S;await Y({type:"popstate",url:s,popped:{state:i,scroll:o,delta:h},accept:()=>{S=r,L=c},block:()=>{history.go(-h)},nav_token:et})}else if(!q){const r=new URL(location.href);t(r)}}),addEventListener("hashchange",()=>{q&&(q=!1,history.replaceState({...history.state,[D]:++S,[M]:L},"",location.href))});for(const e of document.querySelectorAll("link"))e.rel==="icon"&&(e.href=e.href);addEventListener("pageshow",e=>{e.persisted&&U.navigating.set(null)});function t(e){y.url=e,U.page.set({...I,url:e}),U.page.notify()}}async function Ze(t,{status:n=200,error:e,node_ids:a,params:r,route:o,data:i,form:s}){bt=!0;const c=new URL(location.href);({params:r={},route:o={id:null}}=Rt(c,!1)||{});let l;try{const u=a.map(async(d,_)=>{const f=i[_];return f!=null&&f.uses&&(f.uses=oe(f.uses)),St({loader:F.nodes[d],url:c,params:r,route:o,parent:async()=>{const m={};for(let b=0;b<_;b+=1)Object.assign(m,(await u[b]).data);return m},server_data_node:At(f)})}),h=await Promise.all(u),g=ot.find(({id:d})=>d===o.id);if(g){const d=g.layouts;for(let _=0;_<d.length;_++)d[_]||h.splice(_,0,void 0)}l=await nt({url:c,params:r,branch:h,status:n,error:e,form:s,route:g??null})}catch(u){if(u instanceof Kt){await V(new URL(u.location,location.href));return}l=await st({status:X(u),error:await C(u,{url:c,params:r,route:o}),url:c,route:o})}l.props.page&&(l.props.page.state={}),Qt(l,t,!0)}async function re(t,n){var r;const e=new URL(t);e.pathname=_e(t.pathname),t.pathname.endsWith("/")&&e.searchParams.append(qe,"1"),e.searchParams.append(Fe,n.map(o=>o?"1":"0").join(""));const a=await Dt(e.href);if(!a.ok){let o;throw(r=a.headers.get("content-type"))!=null&&r.includes("application/json")?o=await a.json():a.status===404?o="Not Found":a.status===500&&(o="Internal Error"),new rt(a.status,o)}return new Promise(async o=>{var h;const i=new Map,s=a.body.getReader(),c=new TextDecoder;function l(g){return De(g,{Promise:d=>new Promise((_,f)=>{i.set(d,{fulfil:_,reject:f})})})}let u="";for(;;){const{done:g,value:d}=await s.read();if(g&&!u)break;for(u+=!d&&u?`
|
|
1
|
+
import{n as lt,s as ie,x as ce}from"./scheduler.2BOoCPD3.js";import{a as le,b as P}from"./paths.CmHCI0tQ.js";new URL("sveltekit-internal://");function fe(t,n){return t==="/"||n==="ignore"?t:n==="never"?t.endsWith("/")?t.slice(0,-1):t:n==="always"&&!t.endsWith("/")?t+"/":t}function ue(t){return t.split("%25").map(decodeURI).join("%25")}function de(t){for(const n in t)t[n]=decodeURIComponent(t[n]);return t}function ft({href:t}){return t.split("#")[0]}const he=["href","pathname","search","toString","toJSON"];function pe(t,n,e){const a=new URL(t);Object.defineProperty(a,"searchParams",{value:new Proxy(a.searchParams,{get(r,o){if(o==="get"||o==="getAll"||o==="has")return s=>(e(s),r[o](s));n();const i=Reflect.get(r,o);return typeof i=="function"?i.bind(r):i}}),enumerable:!0,configurable:!0});for(const r of he)Object.defineProperty(a,r,{get(){return n(),t[r]},enumerable:!0,configurable:!0});return a}const ge="/__data.json",me=".html__data.json";function _e(t){return t.endsWith(".html")?t.replace(/\.html$/,me):t.replace(/\/$/,"")+ge}function ye(...t){let n=5381;for(const e of t)if(typeof e=="string"){let a=e.length;for(;a;)n=n*33^e.charCodeAt(--a)}else if(ArrayBuffer.isView(e)){const a=new Uint8Array(e.buffer,e.byteOffset,e.byteLength);let r=a.length;for(;r;)n=n*33^a[--r]}else throw new TypeError("value must be a string or TypedArray");return(n>>>0).toString(36)}function we(t){const n=atob(t),e=new Uint8Array(n.length);for(let a=0;a<n.length;a++)e[a]=n.charCodeAt(a);return e.buffer}const Dt=window.fetch;window.fetch=(t,n)=>((t instanceof Request?t.method:(n==null?void 0:n.method)||"GET")!=="GET"&&G.delete(mt(t)),Dt(t,n));const G=new Map;function ve(t,n){const e=mt(t,n),a=document.querySelector(e);if(a!=null&&a.textContent){let{body:r,...o}=JSON.parse(a.textContent);const i=a.getAttribute("data-ttl");return i&&G.set(e,{body:r,init:o,ttl:1e3*Number(i)}),a.getAttribute("data-b64")!==null&&(r=we(r)),Promise.resolve(new Response(r,o))}return window.fetch(t,n)}function be(t,n,e){if(G.size>0){const a=mt(t,e),r=G.get(a);if(r){if(performance.now()<r.ttl&&["default","force-cache","only-if-cached",void 0].includes(e==null?void 0:e.cache))return new Response(r.body,r.init);G.delete(a)}}return window.fetch(n,e)}function mt(t,n){let a=`script[data-sveltekit-fetched][data-url=${JSON.stringify(t instanceof Request?t.url:t)}]`;if(n!=null&&n.headers||n!=null&&n.body){const r=[];n.headers&&r.push([...new Headers(n.headers)].join(",")),n.body&&(typeof n.body=="string"||ArrayBuffer.isView(n.body))&&r.push(n.body),a+=`[data-hash="${ye(...r)}"]`}return a}const Ee=/^(\[)?(\.\.\.)?(\w+)(?:=(\w+))?(\])?$/;function ke(t){const n=[];return{pattern:t==="/"?/^\/$/:new RegExp(`^${Ae(t).map(a=>{const r=/^\[\.\.\.(\w+)(?:=(\w+))?\]$/.exec(a);if(r)return n.push({name:r[1],matcher:r[2],optional:!1,rest:!0,chained:!0}),"(?:/(.*))?";const o=/^\[\[(\w+)(?:=(\w+))?\]\]$/.exec(a);if(o)return n.push({name:o[1],matcher:o[2],optional:!0,rest:!1,chained:!0}),"(?:/([^/]+))?";if(!a)return;const i=a.split(/\[(.+?)\](?!\])/);return"/"+i.map((c,l)=>{if(l%2){if(c.startsWith("x+"))return ut(String.fromCharCode(parseInt(c.slice(2),16)));if(c.startsWith("u+"))return ut(String.fromCharCode(...c.slice(2).split("-").map(f=>parseInt(f,16))));const u=Ee.exec(c),[,h,g,d,_]=u;return n.push({name:d,matcher:_,optional:!!h,rest:!!g,chained:g?l===1&&i[0]==="":!1}),g?"(.*?)":h?"([^/]*)?":"([^/]+?)"}return ut(c)}).join("")}).join("")}/?$`),params:n}}function Se(t){return!/^\([^)]+\)$/.test(t)}function Ae(t){return t.slice(1).split("/").filter(Se)}function Re(t,n,e){const a={},r=t.slice(1),o=r.filter(s=>s!==void 0);let i=0;for(let s=0;s<n.length;s+=1){const c=n[s];let l=r[s-i];if(c.chained&&c.rest&&i&&(l=r.slice(s-i,s+1).filter(u=>u).join("/"),i=0),l===void 0){c.rest&&(a[c.name]="");continue}if(!c.matcher||e[c.matcher](l)){a[c.name]=l;const u=n[s+1],h=r[s+1];u&&!u.rest&&u.optional&&h&&c.chained&&(i=0),!u&&!h&&Object.keys(a).length===o.length&&(i=0);continue}if(c.optional&&c.chained){i++;continue}return}if(!i)return a}function ut(t){return t.normalize().replace(/[[\]]/g,"\\$&").replace(/%/g,"%25").replace(/\//g,"%2[Ff]").replace(/\?/g,"%3[Ff]").replace(/#/g,"%23").replace(/[.*+?^${}()|\\]/g,"\\$&")}function Ie({nodes:t,server_loads:n,dictionary:e,matchers:a}){const r=new Set(n);return Object.entries(e).map(([s,[c,l,u]])=>{const{pattern:h,params:g}=ke(s),d={id:s,exec:_=>{const f=h.exec(_);if(f)return Re(f,g,a)},errors:[1,...u||[]].map(_=>t[_]),layouts:[0,...l||[]].map(i),leaf:o(c)};return d.errors.length=d.layouts.length=Math.max(d.errors.length,d.layouts.length),d});function o(s){const c=s<0;return c&&(s=~s),[c,t[s]]}function i(s){return s===void 0?s:[r.has(s),t[s]]}}function Ct(t,n=JSON.parse){try{return n(sessionStorage[t])}catch{}}function Pt(t,n,e=JSON.stringify){const a=e(n);try{sessionStorage[t]=a}catch{}}const O=[];function _t(t,n=lt){let e;const a=new Set;function r(s){if(ie(t,s)&&(t=s,e)){const c=!O.length;for(const l of a)l[1](),O.push(l,t);if(c){for(let l=0;l<O.length;l+=2)O[l][0](O[l+1]);O.length=0}}}function o(s){r(s(t))}function i(s,c=lt){const l=[s,c];return a.add(l),a.size===1&&(e=n(r,o)||lt),s(t),()=>{a.delete(l),a.size===0&&e&&(e(),e=null)}}return{set:r,update:o,subscribe:i}}const Le="1715266244082",Vt="sveltekit:snapshot",Ft="sveltekit:scroll",qt="sveltekit:states",Pe="sveltekit:pageurl",D="sveltekit:history",M="sveltekit:navigation",J={tap:1,hover:2,viewport:3,eager:4,off:-1,false:-1},z=location.origin;function Gt(t){if(t instanceof URL)return t;let n=document.baseURI;if(!n){const e=document.getElementsByTagName("base");n=e.length?e[0].href:document.URL}return new URL(t,n)}function yt(){return{x:pageXOffset,y:pageYOffset}}function j(t,n){return t.getAttribute(`data-sveltekit-${n}`)}const xt={...J,"":J.hover};function Ht(t){let n=t.assignedSlot??t.parentNode;return(n==null?void 0:n.nodeType)===11&&(n=n.host),n}function Mt(t,n){for(;t&&t!==n;){if(t.nodeName.toUpperCase()==="A"&&t.hasAttribute("href"))return t;t=Ht(t)}}function ht(t,n){let e;try{e=new URL(t instanceof SVGAElement?t.href.baseVal:t.href,document.baseURI)}catch{}const a=t instanceof SVGAElement?t.target.baseVal:t.target,r=!e||!!a||at(e,n)||(t.getAttribute("rel")||"").split(/\s+/).includes("external"),o=(e==null?void 0:e.origin)===z&&t.hasAttribute("download");return{url:e,external:r,target:a,download:o}}function W(t){let n=null,e=null,a=null,r=null,o=null,i=null,s=t;for(;s&&s!==document.documentElement;)a===null&&(a=j(s,"preload-code")),r===null&&(r=j(s,"preload-data")),n===null&&(n=j(s,"keepfocus")),e===null&&(e=j(s,"noscroll")),o===null&&(o=j(s,"reload")),i===null&&(i=j(s,"replacestate")),s=Ht(s);function c(l){switch(l){case"":case"true":return!0;case"off":case"false":return!1;default:return}}return{preload_code:xt[a??"off"],preload_data:xt[r??"off"],keepfocus:c(n),noscroll:c(e),reload:c(o),replace_state:c(i)}}function Ut(t){const n=_t(t);let e=!0;function a(){e=!0,n.update(i=>i)}function r(i){e=!1,n.set(i)}function o(i){let s;return n.subscribe(c=>{(s===void 0||e&&c!==s)&&i(s=c)})}return{notify:a,set:r,subscribe:o}}function xe(){const{set:t,subscribe:n}=_t(!1);let e;async function a(){clearTimeout(e);try{const r=await fetch(`${le}/_app/version.json`,{headers:{pragma:"no-cache","cache-control":"no-cache"}});if(!r.ok)return!1;const i=(await r.json()).version!==Le;return i&&(t(!0),clearTimeout(e)),i}catch{return!1}}return{subscribe:n,check:a}}function at(t,n){return t.origin!==z||!t.pathname.startsWith(n)}const Ue=-1,Te=-2,Ne=-3,Oe=-4,je=-5,$e=-6;function De(t,n){if(typeof t=="number")return r(t,!0);if(!Array.isArray(t)||t.length===0)throw new Error("Invalid input");const e=t,a=Array(e.length);function r(o,i=!1){if(o===Ue)return;if(o===Ne)return NaN;if(o===Oe)return 1/0;if(o===je)return-1/0;if(o===$e)return-0;if(i)throw new Error("Invalid input");if(o in a)return a[o];const s=e[o];if(!s||typeof s!="object")a[o]=s;else if(Array.isArray(s))if(typeof s[0]=="string"){const c=s[0],l=n==null?void 0:n[c];if(l)return a[o]=l(r(s[1]));switch(c){case"Date":a[o]=new Date(s[1]);break;case"Set":const u=new Set;a[o]=u;for(let d=1;d<s.length;d+=1)u.add(r(s[d]));break;case"Map":const h=new Map;a[o]=h;for(let d=1;d<s.length;d+=2)h.set(r(s[d]),r(s[d+1]));break;case"RegExp":a[o]=new RegExp(s[1],s[2]);break;case"Object":a[o]=Object(s[1]);break;case"BigInt":a[o]=BigInt(s[1]);break;case"null":const g=Object.create(null);a[o]=g;for(let d=1;d<s.length;d+=2)g[s[d]]=r(s[d+1]);break;default:throw new Error(`Unknown type ${c}`)}}else{const c=new Array(s.length);a[o]=c;for(let l=0;l<s.length;l+=1){const u=s[l];u!==Te&&(c[l]=r(u))}}else{const c={};a[o]=c;for(const l in s){const u=s[l];c[l]=r(u)}}return a[o]}return r(0)}const Bt=new Set(["load","prerender","csr","ssr","trailingSlash","config"]);[...Bt];const Ce=new Set([...Bt]);[...Ce];function Ve(t){return t.filter(n=>n!=null)}class rt{constructor(n,e){this.status=n,typeof e=="string"?this.body={message:e}:e?this.body=e:this.body={message:`Error: ${n}`}}toString(){return JSON.stringify(this.body)}}class Kt{constructor(n,e){this.status=n,this.location=e}}class wt extends Error{constructor(n,e,a){super(a),this.status=n,this.text=e}}const Fe="x-sveltekit-invalidated",qe="x-sveltekit-trailing-slash";function X(t){return t instanceof rt||t instanceof wt?t.status:500}function Ge(t){return t instanceof wt?t.text:"Internal Error"}const N=Ct(Ft)??{},B=Ct(Vt)??{},U={url:Ut({}),page:Ut({}),navigating:_t(null),updated:xe()};function vt(t){N[t]=yt()}function He(t,n){let e=t+1;for(;N[e];)delete N[e],e+=1;for(e=n+1;B[e];)delete B[e],e+=1}function V(t){return location.href=t.href,new Promise(()=>{})}function Tt(){}let ot,pt,Z,x,gt,F;const zt=[],Q=[];let R=null;const Yt=[],Me=[];let $=[],y={branch:[],error:null,url:null},bt=!1,tt=!1,Nt=!0,K=!1,q=!1,Jt=!1,Et=!1,kt,S,L,I,et;const H=new Set;async function nn(t,n,e){var r,o;document.URL!==location.href&&(location.href=location.href),F=t,ot=Ie(t),x=document.documentElement,gt=n,pt=t.nodes[0],Z=t.nodes[1],pt(),Z(),S=(r=history.state)==null?void 0:r[D],L=(o=history.state)==null?void 0:o[M],S||(S=L=Date.now(),history.replaceState({...history.state,[D]:S,[M]:L},""));const a=N[S];a&&(history.scrollRestoration="manual",scrollTo(a.x,a.y)),e?await Ze(gt,e):We(location.href,{replaceState:!0}),Xe()}function Be(){zt.length=0,Et=!1}function Wt(t){Q.some(n=>n==null?void 0:n.snapshot)&&(B[t]=Q.map(n=>{var e;return(e=n==null?void 0:n.snapshot)==null?void 0:e.capture()}))}function Xt(t){var n;(n=B[t])==null||n.forEach((e,a)=>{var r,o;(o=(r=Q[a])==null?void 0:r.snapshot)==null||o.restore(e)})}function Ot(){vt(S),Pt(Ft,N),Wt(L),Pt(Vt,B)}async function Zt(t,n,e,a){return Y({type:"goto",url:Gt(t),keepfocus:n.keepFocus,noscroll:n.noScroll,replace_state:n.replaceState,state:n.state,redirect_count:e,nav_token:a,accept:()=>{n.invalidateAll&&(Et=!0)}})}async function Ke(t){if(t.id!==(R==null?void 0:R.id)){const n={};H.add(n),R={id:t.id,token:n,promise:te({...t,preload:n}).then(e=>(H.delete(n),e.type==="loaded"&&e.state.error&&(R=null),e))}}return R.promise}async function dt(t){const n=ot.find(e=>e.exec(ee(t)));n&&await Promise.all([...n.layouts,n.leaf].map(e=>e==null?void 0:e[1]()))}function Qt(t,n,e){var o;y=t.state;const a=document.querySelector("style[data-sveltekit]");a&&a.remove(),I=t.props.page,kt=new F.root({target:n,props:{...t.props,stores:U,components:Q},hydrate:e}),Xt(L);const r={from:null,to:{params:y.params,route:{id:((o=y.route)==null?void 0:o.id)??null},url:new URL(location.href)},willUnload:!1,type:"enter",complete:Promise.resolve()};$.forEach(i=>i(r)),tt=!0}async function nt({url:t,params:n,branch:e,status:a,error:r,route:o,form:i}){let s="never";if(P&&(t.pathname===P||t.pathname===P+"/"))s="always";else for(const d of e)(d==null?void 0:d.slash)!==void 0&&(s=d.slash);t.pathname=fe(t.pathname,s),t.search=t.search;const c={type:"loaded",state:{url:t,params:n,branch:e,error:r,route:o},props:{constructors:Ve(e).map(d=>d.node.component),page:I}};i!==void 0&&(c.props.form=i);let l={},u=!I,h=0;for(let d=0;d<Math.max(e.length,y.branch.length);d+=1){const _=e[d],f=y.branch[d];(_==null?void 0:_.data)!==(f==null?void 0:f.data)&&(u=!0),_&&(l={...l,..._.data},u&&(c.props[`data_${h}`]=l),h+=1)}return(!y.url||t.href!==y.url.href||y.error!==r||i!==void 0&&i!==I.form||u)&&(c.props.page={error:r,params:n,route:{id:(o==null?void 0:o.id)??null},state:{},status:a,url:new URL(t),form:i??null,data:u?l:I.data}),c}async function St({loader:t,parent:n,url:e,params:a,route:r,server_data_node:o}){var u,h,g;let i=null,s=!0;const c={dependencies:new Set,params:new Set,parent:!1,route:!1,url:!1,search_params:new Set},l=await t();if((u=l.universal)!=null&&u.load){let d=function(...f){for(const m of f){const{href:b}=new URL(m,e);c.dependencies.add(b)}};const _={route:new Proxy(r,{get:(f,m)=>(s&&(c.route=!0),f[m])}),params:new Proxy(a,{get:(f,m)=>(s&&c.params.add(m),f[m])}),data:(o==null?void 0:o.data)??null,url:pe(e,()=>{s&&(c.url=!0)},f=>{s&&c.search_params.add(f)}),async fetch(f,m){let b;f instanceof Request?(b=f.url,m={body:f.method==="GET"||f.method==="HEAD"?void 0:await f.blob(),cache:f.cache,credentials:f.credentials,headers:f.headers,integrity:f.integrity,keepalive:f.keepalive,method:f.method,mode:f.mode,redirect:f.redirect,referrer:f.referrer,referrerPolicy:f.referrerPolicy,signal:f.signal,...m}):b=f;const A=new URL(b,e);return s&&d(A.href),A.origin===e.origin&&(b=A.href.slice(e.origin.length)),tt?be(b,A.href,m):ve(b,m)},setHeaders:()=>{},depends:d,parent(){return s&&(c.parent=!0),n()},untrack(f){s=!1;try{return f()}finally{s=!0}}};i=await l.universal.load.call(null,_)??null}return{node:l,loader:t,server:o,universal:(h=l.universal)!=null&&h.load?{type:"data",data:i,uses:c}:null,data:i??(o==null?void 0:o.data)??null,slash:((g=l.universal)==null?void 0:g.trailingSlash)??(o==null?void 0:o.slash)}}function jt(t,n,e,a,r,o){if(Et)return!0;if(!r)return!1;if(r.parent&&t||r.route&&n||r.url&&e)return!0;for(const i of r.search_params)if(a.has(i))return!0;for(const i of r.params)if(o[i]!==y.params[i])return!0;for(const i of r.dependencies)if(zt.some(s=>s(new URL(i))))return!0;return!1}function At(t,n){return(t==null?void 0:t.type)==="data"?t:(t==null?void 0:t.type)==="skip"?n??null:null}function ze(t,n){if(!t)return new Set(n.searchParams.keys());const e=new Set([...t.searchParams.keys(),...n.searchParams.keys()]);for(const a of e){const r=t.searchParams.getAll(a),o=n.searchParams.getAll(a);r.every(i=>o.includes(i))&&o.every(i=>r.includes(i))&&e.delete(a)}return e}function $t({error:t,url:n,route:e,params:a}){return{type:"loaded",state:{error:t,url:n,route:e,params:a,branch:[]},props:{page:I,constructors:[]}}}async function te({id:t,invalidating:n,url:e,params:a,route:r,preload:o}){if((R==null?void 0:R.id)===t)return H.delete(R.token),R.promise;const{errors:i,layouts:s,leaf:c}=r,l=[...s,c];i.forEach(p=>p==null?void 0:p().catch(()=>{})),l.forEach(p=>p==null?void 0:p[1]().catch(()=>{}));let u=null;const h=y.url?t!==y.url.pathname+y.url.search:!1,g=y.route?r.id!==y.route.id:!1,d=ze(y.url,e);let _=!1;const f=l.map((p,v)=>{var T;const E=y.branch[v],k=!!(p!=null&&p[0])&&((E==null?void 0:E.loader)!==p[1]||jt(_,g,h,d,(T=E.server)==null?void 0:T.uses,a));return k&&(_=!0),k});if(f.some(Boolean)){try{u=await re(e,f)}catch(p){const v=await C(p,{url:e,params:a,route:{id:t}});return H.has(o)?$t({error:v,url:e,params:a,route:r}):st({status:X(p),error:v,url:e,route:r})}if(u.type==="redirect")return u}const m=u==null?void 0:u.nodes;let b=!1;const A=l.map(async(p,v)=>{var it;if(!p)return;const E=y.branch[v],k=m==null?void 0:m[v];if((!k||k.type==="skip")&&p[1]===(E==null?void 0:E.loader)&&!jt(b,g,h,d,(it=E.universal)==null?void 0:it.uses,a))return E;if(b=!0,(k==null?void 0:k.type)==="error")throw k;return St({loader:p[1],url:e,params:a,route:r,parent:async()=>{var Lt;const It={};for(let ct=0;ct<v;ct+=1)Object.assign(It,(Lt=await A[ct])==null?void 0:Lt.data);return It},server_data_node:At(k===void 0&&p[0]?{type:"skip"}:k??null,p[0]?E==null?void 0:E.server:void 0)})});for(const p of A)p.catch(()=>{});const w=[];for(let p=0;p<l.length;p+=1)if(l[p])try{w.push(await A[p])}catch(v){if(v instanceof Kt)return{type:"redirect",location:v.location};if(H.has(o))return $t({error:await C(v,{params:a,url:e,route:{id:r.id}}),url:e,params:a,route:r});let E=X(v),k;if(m!=null&&m.includes(v))E=v.status??E,k=v.error;else if(v instanceof rt)k=v.body;else{if(await U.updated.check())return await V(e);k=await C(v,{params:a,url:e,route:{id:r.id}})}const T=await Ye(p,w,i);return T?await nt({url:e,params:a,branch:w.slice(0,T.idx).concat(T.node),status:E,error:k,route:r}):await ae(e,{id:r.id},k,E)}else w.push(void 0);return await nt({url:e,params:a,branch:w,status:200,error:null,route:r,form:n?void 0:null})}async function Ye(t,n,e){for(;t--;)if(e[t]){let a=t;for(;!n[a];)a-=1;try{return{idx:a+1,node:{node:await e[t](),loader:e[t],data:{},server:null,universal:null}}}catch{continue}}}async function st({status:t,error:n,url:e,route:a}){const r={};let o=null;if(F.server_loads[0]===0)try{const l=await re(e,[!0]);if(l.type!=="data"||l.nodes[0]&&l.nodes[0].type!=="data")throw 0;o=l.nodes[0]??null}catch{(e.origin!==z||e.pathname!==location.pathname||bt)&&await V(e)}const s=await St({loader:pt,url:e,params:r,route:a,parent:()=>Promise.resolve({}),server_data_node:At(o)}),c={node:await Z(),loader:Z,universal:null,server:null,data:null};return await nt({url:e,params:r,branch:[s,c],status:t,error:n,route:null})}function Rt(t,n){if(!t||at(t,P))return;let e;try{e=F.hooks.reroute({url:new URL(t)})??t.pathname}catch{return}const a=ee(e);for(const r of ot){const o=r.exec(a);if(o)return{id:t.pathname+t.search,invalidating:n,route:r,params:de(o),url:t}}}function ee(t){return ue(t.slice(P.length)||"/")}function ne({url:t,type:n,intent:e,delta:a}){let r=!1;const o=se(y,e,t,n);a!==void 0&&(o.navigation.delta=a);const i={...o.navigation,cancel:()=>{r=!0,o.reject(new Error("navigation cancelled"))}};return K||Yt.forEach(s=>s(i)),r?null:o}async function Y({type:t,url:n,popped:e,keepfocus:a,noscroll:r,replace_state:o,state:i={},redirect_count:s=0,nav_token:c={},accept:l=Tt,block:u=Tt}){const h=Rt(n,!1),g=ne({url:n,type:t,delta:e==null?void 0:e.delta,intent:h});if(!g){u();return}const d=S,_=L;l(),K=!0,tt&&U.navigating.set(g.navigation),et=c;let f=h&&await te(h);if(!f){if(at(n,P))return await V(n);f=await ae(n,{id:null},await C(new wt(404,"Not Found",`Not found: ${n.pathname}`),{url:n,params:{},route:{id:null}}),404)}if(n=(h==null?void 0:h.url)||n,et!==c)return g.reject(new Error("navigation aborted")),!1;if(f.type==="redirect")if(s>=20)f=await st({status:500,error:await C(new Error("Redirect loop"),{url:n,params:{},route:{id:null}}),url:n,route:{id:null}});else return Zt(new URL(f.location,n).href,{},s+1,c),!1;else f.props.page.status>=400&&await U.updated.check()&&await V(n);if(Be(),vt(d),Wt(_),f.props.page.url.pathname!==n.pathname&&(n.pathname=f.props.page.url.pathname),i=e?e.state:i,!e){const w=o?0:1,p={[D]:S+=w,[M]:L+=w,[qt]:i};(o?history.replaceState:history.pushState).call(history,p,"",n),o||He(S,L)}if(R=null,f.props.page.state=i,tt){y=f.state,f.props.page&&(f.props.page.url=n);const w=(await Promise.all(Me.map(p=>p(g.navigation)))).filter(p=>typeof p=="function");if(w.length>0){let p=function(){$=$.filter(v=>!w.includes(v))};w.push(p),$.push(...w)}kt.$set(f.props),Jt=!0}else Qt(f,gt,!1);const{activeElement:m}=document;await ce();const b=e?e.scroll:r?yt():null;if(Nt){const w=n.hash&&document.getElementById(decodeURIComponent(n.hash.slice(1)));b?scrollTo(b.x,b.y):w?w.scrollIntoView():scrollTo(0,0)}const A=document.activeElement!==m&&document.activeElement!==document.body;!a&&!A&&Qe(),Nt=!0,f.props.page&&(I=f.props.page),K=!1,t==="popstate"&&Xt(L),g.fulfil(void 0),$.forEach(w=>w(g.navigation)),U.navigating.set(null)}async function ae(t,n,e,a){return t.origin===z&&t.pathname===location.pathname&&!bt?await st({status:a,error:e,url:t,route:n}):await V(t)}function Je(){let t;x.addEventListener("mousemove",o=>{const i=o.target;clearTimeout(t),t=setTimeout(()=>{a(i,2)},20)});function n(o){a(o.composedPath()[0],1)}x.addEventListener("mousedown",n),x.addEventListener("touchstart",n,{passive:!0});const e=new IntersectionObserver(o=>{for(const i of o)i.isIntersecting&&(dt(i.target.href),e.unobserve(i.target))},{threshold:0});function a(o,i){const s=Mt(o,x);if(!s)return;const{url:c,external:l,download:u}=ht(s,P);if(l||u)return;const h=W(s);if(!h.reload)if(i<=h.preload_data){const g=Rt(c,!1);g&&Ke(g)}else i<=h.preload_code&&dt(c.pathname)}function r(){e.disconnect();for(const o of x.querySelectorAll("a")){const{url:i,external:s,download:c}=ht(o,P);if(s||c)continue;const l=W(o);l.reload||(l.preload_code===J.viewport&&e.observe(o),l.preload_code===J.eager&&dt(i.pathname))}}$.push(r),r()}function C(t,n){if(t instanceof rt)return t.body;const e=X(t),a=Ge(t);return F.hooks.handleError({error:t,event:n,status:e,message:a})??{message:a}}function We(t,n={}){return t=Gt(t),t.origin!==z?Promise.reject(new Error("goto: invalid URL")):Zt(t,n,0)}function Xe(){var n;history.scrollRestoration="manual",addEventListener("beforeunload",e=>{let a=!1;if(Ot(),!K){const r=se(y,void 0,null,"leave"),o={...r.navigation,cancel:()=>{a=!0,r.reject(new Error("navigation cancelled"))}};Yt.forEach(i=>i(o))}a?(e.preventDefault(),e.returnValue=""):history.scrollRestoration="auto"}),addEventListener("visibilitychange",()=>{document.visibilityState==="hidden"&&Ot()}),(n=navigator.connection)!=null&&n.saveData||Je(),x.addEventListener("click",e=>{var g;if(e.button||e.which!==1||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.defaultPrevented)return;const a=Mt(e.composedPath()[0],x);if(!a)return;const{url:r,external:o,target:i,download:s}=ht(a,P);if(!r)return;if(i==="_parent"||i==="_top"){if(window.parent!==window)return}else if(i&&i!=="_self")return;const c=W(a);if(!(a instanceof SVGAElement)&&r.protocol!==location.protocol&&!(r.protocol==="https:"||r.protocol==="http:")||s)return;if(o||c.reload){ne({url:r,type:"link"})?K=!0:e.preventDefault();return}const[u,h]=r.href.split("#");if(h!==void 0&&u===ft(location)){const[,d]=y.url.href.split("#");if(d===h){e.preventDefault(),h===""||h==="top"&&a.ownerDocument.getElementById("top")===null?window.scrollTo({top:0}):(g=a.ownerDocument.getElementById(h))==null||g.scrollIntoView();return}if(q=!0,vt(S),t(r),!c.replace_state)return;q=!1}e.preventDefault(),Y({type:"link",url:r,keepfocus:c.keepfocus,noscroll:c.noscroll,replace_state:c.replace_state??r.href===location.href})}),x.addEventListener("submit",e=>{if(e.defaultPrevented)return;const a=HTMLFormElement.prototype.cloneNode.call(e.target),r=e.submitter;if(((r==null?void 0:r.formMethod)||a.method)!=="get")return;const i=new URL((r==null?void 0:r.hasAttribute("formaction"))&&(r==null?void 0:r.formAction)||a.action);if(at(i,P))return;const s=e.target,c=W(s);if(c.reload)return;e.preventDefault(),e.stopPropagation();const l=new FormData(s),u=r==null?void 0:r.getAttribute("name");u&&l.append(u,(r==null?void 0:r.getAttribute("value"))??""),i.search=new URLSearchParams(l).toString(),Y({type:"form",url:i,keepfocus:c.keepfocus,noscroll:c.noscroll,replace_state:c.replace_state??i.href===location.href})}),addEventListener("popstate",async e=>{var a;if((a=e.state)!=null&&a[D]){const r=e.state[D];if(et={},r===S)return;const o=N[r],i=e.state[qt]??{},s=new URL(e.state[Pe]??location.href),c=e.state[M],l=ft(location)===ft(y.url);if(c===L&&(Jt||l)){t(s),N[S]=yt(),o&&scrollTo(o.x,o.y),i!==I.state&&(I={...I,state:i},kt.$set({page:I})),S=r;return}const h=r-S;await Y({type:"popstate",url:s,popped:{state:i,scroll:o,delta:h},accept:()=>{S=r,L=c},block:()=>{history.go(-h)},nav_token:et})}else if(!q){const r=new URL(location.href);t(r)}}),addEventListener("hashchange",()=>{q&&(q=!1,history.replaceState({...history.state,[D]:++S,[M]:L},"",location.href))});for(const e of document.querySelectorAll("link"))e.rel==="icon"&&(e.href=e.href);addEventListener("pageshow",e=>{e.persisted&&U.navigating.set(null)});function t(e){y.url=e,U.page.set({...I,url:e}),U.page.notify()}}async function Ze(t,{status:n=200,error:e,node_ids:a,params:r,route:o,data:i,form:s}){bt=!0;const c=new URL(location.href);({params:r={},route:o={id:null}}=Rt(c,!1)||{});let l;try{const u=a.map(async(d,_)=>{const f=i[_];return f!=null&&f.uses&&(f.uses=oe(f.uses)),St({loader:F.nodes[d],url:c,params:r,route:o,parent:async()=>{const m={};for(let b=0;b<_;b+=1)Object.assign(m,(await u[b]).data);return m},server_data_node:At(f)})}),h=await Promise.all(u),g=ot.find(({id:d})=>d===o.id);if(g){const d=g.layouts;for(let _=0;_<d.length;_++)d[_]||h.splice(_,0,void 0)}l=await nt({url:c,params:r,branch:h,status:n,error:e,form:s,route:g??null})}catch(u){if(u instanceof Kt){await V(new URL(u.location,location.href));return}l=await st({status:X(u),error:await C(u,{url:c,params:r,route:o}),url:c,route:o})}l.props.page&&(l.props.page.state={}),Qt(l,t,!0)}async function re(t,n){var r;const e=new URL(t);e.pathname=_e(t.pathname),t.pathname.endsWith("/")&&e.searchParams.append(qe,"1"),e.searchParams.append(Fe,n.map(o=>o?"1":"0").join(""));const a=await Dt(e.href);if(!a.ok){let o;throw(r=a.headers.get("content-type"))!=null&&r.includes("application/json")?o=await a.json():a.status===404?o="Not Found":a.status===500&&(o="Internal Error"),new rt(a.status,o)}return new Promise(async o=>{var h;const i=new Map,s=a.body.getReader(),c=new TextDecoder;function l(g){return De(g,{Promise:d=>new Promise((_,f)=>{i.set(d,{fulfil:_,reject:f})})})}let u="";for(;;){const{done:g,value:d}=await s.read();if(g&&!u)break;for(u+=!d&&u?`
|
|
2
2
|
`:c.decode(d,{stream:!0});;){const _=u.indexOf(`
|
|
3
3
|
`);if(_===-1)break;const f=JSON.parse(u.slice(0,_));if(u=u.slice(_+1),f.type==="redirect")return o(f);if(f.type==="data")(h=f.nodes)==null||h.forEach(m=>{(m==null?void 0:m.type)==="data"&&(m.uses=oe(m.uses),m.data=l(m.data))}),o(f);else if(f.type==="chunk"){const{id:m,data:b,error:A}=f,w=i.get(m);i.delete(m),A?w.reject(l(A)):w.fulfil(l(b))}}}})}function oe(t){return{dependencies:new Set((t==null?void 0:t.dependencies)??[]),params:new Set((t==null?void 0:t.params)??[]),parent:!!(t!=null&&t.parent),route:!!(t!=null&&t.route),url:!!(t!=null&&t.url),search_params:new Set((t==null?void 0:t.search_params)??[])}}function Qe(){const t=document.querySelector("[autofocus]");if(t)t.focus();else{const n=document.body,e=n.getAttribute("tabindex");n.tabIndex=-1,n.focus({preventScroll:!0,focusVisible:!1}),e!==null?n.setAttribute("tabindex",e):n.removeAttribute("tabindex");const a=getSelection();if(a&&a.type!=="None"){const r=[];for(let o=0;o<a.rangeCount;o+=1)r.push(a.getRangeAt(o));setTimeout(()=>{if(a.rangeCount===r.length){for(let o=0;o<a.rangeCount;o+=1){const i=r[o],s=a.getRangeAt(o);if(i.commonAncestorContainer!==s.commonAncestorContainer||i.startContainer!==s.startContainer||i.endContainer!==s.endContainer||i.startOffset!==s.startOffset||i.endOffset!==s.endOffset)return}a.removeAllRanges()}})}}}function se(t,n,e,a){var c,l;let r,o;const i=new Promise((u,h)=>{r=u,o=h});return i.catch(()=>{}),{navigation:{from:{params:t.params,route:{id:((c=t.route)==null?void 0:c.id)??null},url:t.url},to:e&&{params:(n==null?void 0:n.params)??null,route:{id:((l=n==null?void 0:n.route)==null?void 0:l.id)??null},url:e},willUnload:!n,type:a,complete:i},fulfil:r,reject:o}}export{rt as H,nn as a,We as g,U as s,_t as w};
|
|
@@ -59,7 +59,7 @@ ENDSEC
|
|
|
59
59
|
0
|
|
60
60
|
EOF
|
|
61
61
|
`}stringify(){return this.close(),this.dxfStr}};function Fc(){return new Ec}function Sc(e,n,t){return{circle:!0,cx:e,cy:n,radius:t}}var kc=class{constructor(){I(this,"seg");this.seg=[]}addStart(e,n){this.seg=[];const t={typ:0,px:e,py:n};this.seg.push(t)}addStroke(e,n){const t={typ:1,px:e,py:n};this.seg.push(t)}addArc(e,n,t,r,s){const i={typ:2,px:e,py:n,radius:t,large:r,ccw:s};this.seg.push(i)}toJson(){return{circle:!1,seg:this.seg}}};function Tc(){return new kc}var zi=class{},Bc=class Mt extends zi{constructor(t,r,s=""){super();I(this,"circle",!1);I(this,"segments");I(this,"points");I(this,"debugPoints");I(this,"debugLines");I(this,"lastPoint");I(this,"imposedColor");this.segments=[new et(6,t,r,0)],this.points=[],this.debugPoints=[],this.debugLines=[],this.lastPoint=Z(t,r),this.imposedColor=s}setLastPoint(t,r){this.lastPoint=Z(t,r)}getLastPoint(){return this.lastPoint}getFirstPoint(){return Z(this.segments[0].px,this.segments[0].py)}addPointA(t,r){if(this.points.length>2)throw`err311: contour add too much point ${t} ${r}`;return this.points.push(Z(t,r)),this}addPointAP(t,r){const s=Z(0,0).translatePolar(t,r);return this.addPointA(s.cx,s.cy),this}addPointR(t,r){const i=this.getLastPoint().translate(t,r);return this.addPointA(i.cx,i.cy),this}addPointRP(t,r){const i=this.getLastPoint().translatePolar(t,r);return this.addPointA(i.cx,i.cy),this}addSeg(t){return this.segments.push(t),this}addSegStroke(){if(this.points.length!==1)throw`err554: contour addSegStroke with unexpected points.length ${this.points.length}`;const t=this.points.pop();if(t!==void 0){const r=new et(0,t.cx,t.cy,0);t.isEqual(this.getLastPoint())||(this.addSeg(r),this.setLastPoint(t.cx,t.cy))}else throw"err284: contour p1 is undefined";return this}addSegStrokeA(t,r){return this.addPointA(t,r).addSegStroke(),this}addSegStrokeAP(t,r){return this.addPointAP(t,r).addSegStroke(),this}addSegStrokeR(t,r){return this.addPointR(t,r).addSegStroke(),this}addSegStrokeRP(t,r){return this.addPointRP(t,r).addSegStroke(),this}addSegArc(t,r,s){if(this.points.length!==1)throw`err954: contour addSegArc with unexpected points.length ${this.points.length}`;const i=this.points.pop();if(i!==void 0){const o=new et(1,i.cx,i.cy,t,r,s);i.isEqual(this.getLastPoint())?console.log(`warn144: addSegArc last and new point identical ${st(i.cx)} ${st(i.cy)}`):(this.addSeg(o),this.setLastPoint(i.cx,i.cy))}else throw"err482: contour p1 is undefined";return this}addSegArc2(){if(this.points.length!==2)throw`err958: contour addSegArc2 with unexpected points.length ${this.points.length}`;const t=this.points.pop(),r=this.points.pop();if(r!==void 0&&t!==void 0){const s=this.getLastPoint(),i=cc(s,r,t),o=i.distanceToPoint(s),u=s.middlePoint(t),a=u.angleToPoint(s),f=u.angleToPoint(r),c=ce(f-a);let h=!1,m=!1;if(!u.isEqual(i)){const x=u.angleToPoint(i),b=ce(x-a);Math.sign(b)*Math.sign(c)>0&&(h=!0)}Math.sign(c)>0&&(m=!0),this.addPointA(t.cx,t.cy).addSegArc(o,h,m),this.debugPoints.push(r)}else throw"err488: contour p1 or p2 or seg is undefined";return this}addSegArc3(t,r){if(this.points.length!==1)throw`err914: contour addSegArc3 with unexpected points.length ${this.points.length}`;const s=this.points.pop();if(s!==void 0){const i=this.getLastPoint(),o=kr(i,s);let u=s;r&&(u=i);const a=Wn(u.cx,u.cy,t+Math.PI/2),f=o.intersection(a),c=f.distanceToPoint(i),h=i.middlePoint(s),m=u.angleToPoint(h),x=ce(t-m);let b=!1;Math.abs(x)>Math.PI/2&&(b=!0);let l=!1;x<0&&(l=!0),r||(l=!l),this.addPointA(s.cx,s.cy).addSegArc(c,b,l),this.debugPoints.push(h),this.debugPoints.push(f)}else throw"err282: contour p1 is undefined";return this}addSeg2Arcs(t,r){if(this.points.length!==1)throw`err214: contour addSeg2Arcs with unexpected points.length ${this.points.length}`;const s=this.points.pop();if(s!==void 0){const i=this.getLastPoint(),o=i.distanceToPoint(s),u=i.angleToPoint(s),a=s.angleToPoint(i),f=ce(t-u),c=-1*ce(r-a);if(Math.abs(f)>=Math.PI/2)throw`err545: addSeg2Arcs with too large au ${f}`;if(Math.abs(c)>=Math.PI/2)throw`err546: addSeg2Arcs with too large av ${c}`;if(te(f)===0)throw`err765: addSeg2Arcs with almost zero au ${f}`;if(te(c)===0)throw`err766: addSeg2Arcs with almost zero av ${c}`;if(Math.sign(f)*Math.sign(c)<1)throw`err767: addSeg2Arcs with au/av bad orientation ${f} ${c}`;const h=Math.tan(f/2),m=Math.tan(c/2),x=o*m/(m+h),b=Math.abs(x/Math.sin(f)),l=x/Math.cos(f/2),d=o*h/(m+h),p=Math.abs(d/Math.sin(c)),D=i.translatePolar(u+f/2,l);let g=!1;Math.sign(f)<0&&(g=!0),this.addPointA(D.cx,D.cy).addSegArc(b,!1,g),this.addPointA(s.cx,s.cy).addSegArc(p,!1,g),this.debugPoints.push(i.translatePolar(u,x)),this.debugPoints.push(i.translatePolar(u+f-Math.sign(f)*Math.PI/2,b)),this.debugPoints.push(s.translatePolar(a-c+Math.sign(f)*Math.PI/2,p))}else throw"err182: contour p1 is undefined";return this}addCornerPointed(){const t=new et(2,0,0,0);return this.addSeg(t),this}addCornerRounded(t){const r=new et(3,0,0,t);return this.addSeg(r),this}addCornerWidened(t){const r=new et(4,0,0,t);return this.addSeg(r),this}addCornerWideAcc(t){const r=new et(5,0,0,t);return this.addSeg(r),this}closeSegStroke(){const t=this.segments[0].px,r=this.segments[0].py;return this.addSegStrokeA(t,r),this}closeSegArc(t,r,s){const i=this.segments[0].px,o=this.segments[0].py;return this.addPointA(i,o).addSegArc(t,r,s),this}clone(){const t=new Mt(this.segments[0].px,this.segments[0].py);for(const r of this.segments){const s=r.clone();s.sType!==6&&(t.addSeg(s),He(s.sType)&&t.setLastPoint(s.px,s.py))}return t}translate(t,r){const s=this.segments[0].px+t,i=this.segments[0].py+r,o=new Mt(s,i);for(const u of this.segments){const a=u.clone();He(u.sType)&&(a.px+=t,a.py+=r),a.sType!==6&&(o.addSeg(a),He(a.sType)&&o.setLastPoint(a.px,a.py))}return o}translatePolar(t,r){return this.translate(r*Math.cos(t),r*Math.sin(t))}rotate(t,r,s){const i=Z(t,r),u=Z(this.segments[0].px,this.segments[0].py).rotate(i,s),a=new Mt(u.cx,u.cy);for(const f of this.segments){const c=f.clone();if(He(f.sType)){const m=Z(c.px,c.py).rotate(i,s);c.px=m.cx,c.py=m.cy}c.sType!==6&&(a.addSeg(c),He(c.sType)&&a.setLastPoint(c.px,c.py))}return a}scale(t,r,s,i=!1){const o=Z(t,r),a=Z(this.segments[0].px,this.segments[0].py).scale(o,s),f=new Mt(a.cx,a.cy);for(const c of this.segments){const h=c.clone();if(He(c.sType)){const x=Z(h.px,h.py).scale(o,s);h.px=x.cx,h.py=x.cy}c.sType===1&&(h.radius*=s),Bn(c.sType)&&i&&(h.radius*=s),h.sType!==6&&(f.addSeg(h),He(h.sType)&&f.setLastPoint(h.px,h.py))}return f}addPartial(t){if(this.points.length>0)throw`err911: addPartial, points should be used ${this.points.length}`;let r=t;if(t.segments.length>0){const s=t.segments[0],i=this.getLastPoint(),o=s.px-i.cx,u=s.py-i.cy;s.sType===6&&(r=t.translate(-o,-u))}for(const s of r.segments)s.sType!==6&&(this.addSeg(s),He(s.sType)&&this.setLastPoint(s.px,s.py));return this}draw(t,r,s=de.contour){const i=this.imposedColor===""?s:this.imposedColor;let o=0,u=0;for(const a of this.segments){if(a.sType===0){const[f,c]=Lt(o,u,r),[h,m]=Lt(a.px,a.py,r);t.beginPath(),t.moveTo(f,c),t.lineTo(h,m),t.strokeStyle=i,t.stroke()}if(a.sType===1)try{const f=vt(o,u,a),[c,h]=Lt(f.pc.cx,f.pc.cy,r),m=Zi(a.radius,r);t.beginPath(),t.arc(c,h,m,-f.a1,-f.a2,a.arcCcw),t.strokeStyle=i,t.stroke()}catch(f){console.log("err413: "+f)}Qt(a.sType)&&(o=a.px,u=a.py)}}extractSkeleton(){const t=this.segments[0],r=new Mt(t.px,t.py);for(const s of this.segments)He(s.sType)&&r.addSeg(s);return r}generateContour(){At.clearPoints(),At.clearLines();const t=[],r=[];let s=0,i=0,o=0;for(const c of this.segments){if(c.sType===0){const x=Z(i,o),b=Z(c.px,c.py),l=Z(0,0);t.push(new Ve(c.sType,x,b,l,0,0,0,!1)),s=1}if(c.sType===1){const x=vt(i,o,c);t.push(x),s=1}const h=t.at(-1),m=t.at(-2);if(h!==void 0&&m!==void 0&&He(h.sType)&&mr(m.sType)){const x=t.pop(),b=t.pop(),l=t.pop();if(l!==void 0&&b!==void 0&&x!==void 0){const d=Xs(l,b,x);t.push(...d)}else throw"err603: contour generateContour internal error"}if(mr(c.sType)){if(s===2)throw`err419: generateContour with two consecutive corners ${c.sType}`;if(s===0&&Bn(c.sType)&&c.radius>0){const x=Z(0,0);r.push(new Ve(c.sType,x,x,x,c.radius,0,0,!1))}if(s===1&&Bn(c.sType)&&c.radius>0){const x=Z(0,0);t.push(new Ve(c.sType,x,x,x,c.radius,0,0,!1))}s=2}Qt(c.sType)&&(i=c.px,o=c.py)}if(r.length>0)if(s===1)t.push(...r);else throw"err397: contour generateContour Corners defined at end and begining";const u=t.at(-1);if(u!==void 0&&mr(u.sType)){const c=t[0],h=t.pop(),m=t.pop();if(m!==void 0&&h!==void 0&&c!==void 0){const x=Xs(m,h,c);t.push(...x.slice(0,-1));const b=x.at(-1);if(b!==void 0)t[0]=b;else throw"err606: contour generateContour internal error"}else throw"err602: contour generateContour internal error"}const a=t[0],f=new Mt(a.p1.cx,a.p1.cy,this.imposedColor);f.debugPoints.push(...At.getPoints()),f.debugLines.push(...At.getLines());for(const c of t)if(c.sType===0)f.addSegStrokeA(c.p2.cx,c.p2.cy);else if(c.sType===1){const h=fc(c);f.addPointA(c.p2.cx,c.p2.cy).addSegArc(h.radius,h.arcLarge,h.arcCcw)}else throw`err986: contour generateContour unexpected in seg2 Enum ${c.sType}`;return f}generatePoints(){const t=[];t.push(...this.debugPoints);const r=this.segments[0];t.push(Z(r.px,r.py));let s=0,i=0;for(const o of this.segments){if(o.sType===1)try{const u=vt(s,i,o),a=Z(u.pc.cx,u.pc.cy),f=ce((u.a2-u.a1)/2);let c=u.a1+f;(Math.sign(f)>0&&!o.arcCcw||Math.sign(f)<0&&o.arcCcw)&&(c+=Math.PI);const h=a.translatePolar(c,o.radius);t.push(h)}catch(u){console.log("err453: "+u)}Qt(o.sType)&&(s=o.px,i=o.py,t.push(Z(s,i)))}return t}generateLines(){const t=[];return t.push(...this.debugLines),t}checkContour(t){if(t.segments[0].sType!==6)throw`err412: contour check first seg is not eStart ${t.segments[0].sType}`;let r=0,s=0;for(const u of t.segments){if(u.sType===1)try{vt(r,s,u)}catch(a){throw`err778: ${a}`}Qt(u.sType)&&(r=u.px,s=u.py)}const i=t.segments[0].px,o=t.segments[0].py;if(te(r-i)!==0||te(s-o)!==0)throw`err414: contour check, contour is not closed px ${i} ${r} py ${i} ${o}`}check(){At.clearMsg(),this.checkContour(this);const t=this.generateContour();return this.checkContour(t),At.getMsg()}toSvg(t,r=""){const s=yc();for(const o of this.segments)o.sType===6?s.addStart(o.px,t-o.py):o.sType===0?s.addStroke(o.px,t-o.py):o.sType===1?s.addArc(o.px,t-o.py,o.radius,o.arcLarge,!o.arcCcw):console.log(`err631: contour.toSvg has unknown segment type ${o.sType}`);return s.stringify(r)}toDxfSeg(){const t=[];let r=0,s=0;for(const i of this.segments){if(i.sType===0)t.push(Ac(r,s,i.px,i.py));else if(i.sType===1)try{const o=vt(r,s,i);t.push(vc(o.pc.cx,o.pc.cy,i.radius,o.a1,o.a2,o.arcCcw))}catch(o){console.log("err413: "+o)}Qt(i.sType)&&(r=i.px,s=i.py)}return t}toPax(){const t=Tc();for(const s of this.segments)s.sType===6?t.addStart(s.px,s.py):s.sType===0?t.addStroke(s.px,s.py):s.sType===1?t.addArc(s.px,s.py,s.radius,s.arcLarge,s.arcCcw):console.log(`err709: contour.toPax has unknown segment type ${s.sType}`);return t.toJson()}getPerimeter(){let t=0;const r=this.generateContour();let s=0,i=0;for(const o of r.segments)if(o.sType===6)s=o.px,i=o.py;else if(o.sType===0){const u=Math.sqrt((o.px-s)**2+(o.py-i)**2);s=o.px,i=o.py,t+=u}else if(o.sType===1){const u=vt(s,i,o),a=Ft(u.a2-u.a1),f=u.arcCcw?a:Ft(2*Math.PI-a),c=o.radius*f;s=o.px,i=o.py,t+=c}else console.log(`err760: contour.getPerimeter has unknown segment type ${o.sType}`);return t}},Pc=class qt extends zi{constructor(t,r,s,i=""){super();I(this,"circle",!0);I(this,"px");I(this,"py");I(this,"radius");I(this,"imposedColor");if(this.px=t,this.py=r,this.radius=s,this.imposedColor=i,s<0)throw`err432: iRadius ${s} is negative at circle ix ${t}, iy ${r}`}clone(){return new qt(this.px,this.py,this.radius,this.imposedColor)}translate(t,r){return new qt(this.px+t,this.py+r,this.radius,this.imposedColor)}translatePolar(t,r){return this.translate(r*Math.cos(t),r*Math.sin(t))}rotate(t,r,s){const i=Z(t,r),o=Z(this.px,this.py).rotate(i,s);return new qt(o.cx,o.cy,this.radius,this.imposedColor)}draw(t,r,s=de.contour){const[i,o]=Lt(this.px,this.py,r),u=Zi(this.radius,r),a=this.imposedColor===""?s:this.imposedColor;t.beginPath(),t.arc(i,o,u,0,2*Math.PI,!0),t.strokeStyle=a,t.stroke()}extractSkeleton(){return new qt(this.px,this.py,this.radius)}generateContour(){return new qt(this.px,this.py,this.radius,this.imposedColor)}generatePoints(){const t=[],r=Z(this.px,this.py);t.push(r);for(let s=0;s<4;s++){const i=r.translatePolar(s*Math.PI/2,this.radius);t.push(i)}return t}generateLines(){return[]}check(){return""}toSvg(t,r=""){return gc(this.px,t-this.py,this.radius,r)}toDxfSeg(){const t=[];return t.push(Cc(this.px,this.py,this.radius)),t}toPax(){return Sc(this.px,this.py,this.radius)}getPerimeter(){return 2*Math.PI*this.radius}};function Vr(e,n,t=""){return new Bc(e,n,t)}function T0(e,n,t,r=""){return new Pc(e,n,t,r)}var Mc=class Tr{constructor(){I(this,"pointList");I(this,"lineList");I(this,"vectorList");I(this,"mainList");I(this,"mainBList");I(this,"secondList");I(this,"secondBList");I(this,"dynamicsList");I(this,"xMin");I(this,"xMax");I(this,"yMin");I(this,"yMax");this.pointList=[],this.lineList=[],this.vectorList=[],this.mainList=[],this.mainBList=[],this.secondList=[],this.secondBList=[],this.dynamicsList=[],this.xMin=0,this.xMax=0,this.yMin=0,this.yMax=0}addPoint(n){this.pointList.push(n)}addPoints(n){this.pointList.push(...n)}addLine(n){this.lineList.push(n)}addLines(n){for(const t of n)this.lineList.push(t)}addVector(n){this.vectorList.push(n)}addMain(n){const t=n.generateContour();this.addPoints(t.generatePoints()),this.addLines(t.generateLines()),this.mainList.push(t),this.mainBList.push(n.extractSkeleton())}addSecond(n){const t=n.generateContour();this.addPoints(t.generatePoints()),this.addLines(t.generateLines()),this.secondList.push(t),this.secondBList.push(n.extractSkeleton())}addDynamics(n){this.addPoints(n.generatePoints()),this.addLines(n.generateLines()),this.dynamicsList.push(n)}translate(n,t){const r=new Tr;for(const s of this.pointList)r.addPoint(s.translate(n,t));for(const s of this.lineList)r.addLine(s.translate(n,t));for(const s of this.vectorList)r.addVector(s.translate(n,t));for(const s of this.mainList)r.addMain(s.translate(n,t));for(const s of this.secondList)r.addSecond(s.translate(n,t));for(const s of this.dynamicsList)r.addDynamics(s.translate(n,t));return r}translatePolar(n,t){return this.translate(t*Math.cos(n),t*Math.sin(n))}rotate(n,t,r){const s=new Tr,i=Z(n,t);for(const o of this.pointList)s.addPoint(o.rotate(i,r));for(const o of this.lineList)s.addLine(o.rotate(i,r));for(const o of this.vectorList)s.addVector(o.rotate(i,r));for(const o of this.mainList)s.addMain(o.rotate(n,t,r));for(const o of this.secondList)s.addSecond(o.rotate(n,t,r));for(const o of this.dynamicsList)s.addDynamics(o.rotate(n,t,r));return s}mergeFigure(n,t=!1){for(const r of n.pointList)this.addPoint(r.clone());for(const r of n.lineList)this.addLine(r.clone());for(const r of n.vectorList)this.addVector(r.clone());for(const r of n.mainList)t?this.addSecond(r.clone()):this.addMain(r.clone());for(const r of n.secondList)this.addSecond(r.clone());for(const r of n.dynamicsList)this.addDynamics(r.clone())}clear(){this.pointList=[],this.lineList=[],this.vectorList=[],this.mainList=[],this.mainBList=[],this.secondList=[],this.secondBList=[],this.dynamicsList=[]}getMinMax(){[this.xMin,this.xMax,this.yMin,this.yMax]=Yi(this.pointList)}getAdjustFull(n,t){let r=Fr();return this.pointList.length>0&&(this.getMinMax(),r=Sr(this.xMin,this.xMax,this.yMin,this.yMax,n,t)),r}getAdjustZoom(n,t){let r=Fr();if(this.pointList.length>0){this.getMinMax();const s=(this.xMin+this.xMax)/2,i=(this.yMin+this.yMax)/2;r=Sr(s,this.xMax,i,this.yMax,n,t)}return r}quantifyRuler(n,t){const s=n/10/t.scaleX;let i=1e-4;for(;i<s;)i*=10;i/5>s?i/=5:i/2>s&&(i/=2);const o=i*t.scaleX;return[i,o]}drawRuler(n,t,r){const[s,i]=this.quantifyRuler(n.canvas.width,t),o=n.canvas.width-10-i;n.font="15px Arial",n.fillStyle=r,n.fillText(`${s.toFixed(4)}`,o,20),n.beginPath(),n.moveTo(o,25),n.lineTo(o+i,25),n.lineTo(o+i,25+i),n.strokeStyle=r,n.stroke()}draw(n,t,r){if(r.points)for(const s of this.pointList)s.draw(n,t);if(r.lines)for(const s of this.lineList)s.draw(n,t);if(r.vectors)for(const s of this.vectorList)s.draw(n,t);if(r.main)for(const s of this.mainList)s.draw(n,t,de.main);if(r.mainB)for(const s of this.mainBList)s.draw(n,t,de.mainB);if(r.second)for(const s of this.secondList)s.draw(n,t,de.second);if(r.secondB)for(const s of this.secondBList)s.draw(n,t,de.secondB);if(r.dynamics)for(const s of this.dynamicsList)s.draw(n,t,de.dynamics);if(r.ruler&&this.drawRuler(n,t,de.ruler),r.refframe){for(const s of[10,100,200])Z(s,0).draw(n,t,de.reference,2),Z(-s,0).draw(n,t,de.reference,2),Z(0,s).draw(n,t,de.reference,2),Z(0,-s).draw(n,t,de.reference,2);Z(0,0).draw(n,t,de.origin,2)}}};function Ic(){return new Mc}function Br(e){const n=Ic();for(const t in e){const r=e[t];for(const s of r.pointList)n.pointList.push(s);for(const s of r.lineList)n.lineList.push(s);for(const s of r.vectorList)n.vectorList.push(s);for(const s of r.mainList)n.mainList.push(s);for(const s of r.mainBList)n.mainBList.push(s);for(const s of r.secondList)n.secondList.push(s);for(const s of r.secondBList)n.secondBList.push(s);for(const s of r.dynamicsList)n.dynamicsList.push(s)}return n}function B0(){return{points:!1,lines:!1,vectors:!1,main:!0,mainB:!1,second:!0,secondB:!1,dynamics:!1,ruler:!0,refframe:!1}}function P0(e){return{points:e.points,lines:e.lines,vectors:e.vectors,main:e.main,mainB:e.mainB,second:e.second,secondB:e.secondB,dynamics:e.dynamics,ruler:e.ruler,refframe:e.refframe}}var Lc=(e=>(e[e.eNumber=0]="eNumber",e[e.eCheckbox=1]="eCheckbox",e[e.eDropdown=2]="eDropdown",e[e.eSectionSeparator=3]="eSectionSeparator",e))(Lc||{}),Kn={partName:"",params:[],paramSvg:{},sim:{tMax:0,tStep:0,tUpdate:0}};function Nc(e,n,t){return{val:e,init:n,chg:t}}function $c(e){const n={};for(const t of Object.keys(e))n[t]=e[t].val;return n}var Rc=class{constructor(e,n=""){I(this,"paramVal",{});I(this,"paramInit",{});I(this,"paramChanged",{});I(this,"partName");I(this,"suffix");I(this,"paramNames");for(const t of e.params)this.paramVal[t.name]=t.init,this.paramInit[t.name]=t.init,this.paramChanged[t.name]=!1;this.suffix=n,this.partName=e.partName,this.paramNames=this.getParamName()}getParamName(){const e=[];for(const n of Object.keys(this.paramVal))e.push(n);return e}getPartName(){return this.partName}getPartNameSuffix(){return this.partName+this.suffix}getSuffix(){return this.suffix}getParamVal(){return this.paramVal}getVal(e){if(this.paramNames.includes(e))return this.paramVal[e];throw`err140: parameter ${e} does not exist in design ${this.partName}`}getInit(e){if(this.paramNames.includes(e))return this.paramInit[e];throw`err149: parameter ${e} does not exist in design ${this.partName}`}getChanged(e){if(this.paramNames.includes(e))return this.paramChanged[e];throw`err156: parameter ${e} does not exist in design ${this.partName}`}setVal(e,n){if(this.paramNames.includes(e))this.paramVal[e]=n,this.paramChanged[e]=!0;else throw`err163: parameter ${e} does not exist in design ${this.partName}`}applyParamVal(e){let n="";for(const t of Object.keys(e))this.setVal(t,e[t]);return n+=`info104: apply ${Object.keys(e).length} parameters on ${this.partName}
|
|
62
|
-
`,n}applyParamList(e){return this.applyParamVal($c(e))}getDesignParamList(){const e={};for(const n of this.paramNames)e[n]=Nc(this.getVal(n),this.getInit(n),this.getChanged(n));return e}};function M0(e,n=""){return new Rc(e,n)}function I0(e,n,t,r=0,s=100,i=1){return{name:e,unit:n,init:t,min:r,max:s,step:i,dropdown:[],pType:0}}function L0(e,n){return{name:e,unit:"checkbox",init:n?1:0,min:0,max:1,step:1,dropdown:[],pType:1}}function N0(e,n){return{name:e,unit:"dropdown",init:
|
|
62
|
+
`,n}applyParamList(e){return this.applyParamVal($c(e))}getDesignParamList(){const e={};for(const n of this.paramNames)e[n]=Nc(this.getVal(n),this.getInit(n),this.getChanged(n));return e}};function M0(e,n=""){return new Rc(e,n)}function I0(e,n,t,r=0,s=100,i=1){return{name:e,unit:n,init:t,min:r,max:s,step:i,dropdown:[],pType:0}}function L0(e,n){return{name:e,unit:"checkbox",init:n?1:0,min:0,max:1,step:1,dropdown:[],pType:1}}function N0(e,n,t=0){let r=0;return t<n.length&&(r=t),{name:e,unit:"dropdown",init:r,min:0,max:n.length-1,step:1,dropdown:n,pType:2}}function $0(e){return{name:e,unit:"section-separator",init:0,min:0,max:0,step:0,dropdown:[],pType:3}}var Oc=(e=>(e[e.eLinearOrtho=0]="eLinearOrtho",e[e.eRotate=1]="eRotate",e))(Oc||{}),jc=(e=>(e[e.eIdentity=0]="eIdentity",e[e.eIntersection=1]="eIntersection",e[e.eUnion=2]="eUnion",e[e.eSubstraction=3]="eSubstraction",e))(jc||{});function R0(e){return{partName:e,calcErr:!0,logstr:"",fig:{},vol:{extrudes:[],volumes:[]},sub:{}}}function O0(e){if(e.calcErr){let n=`err182: Error in sub-design ${e.partName}
|
|
63
63
|
`;throw n+=Uc(e.logstr,e.partName),n}}function Uc(e,n){let t="";for(const r of e.split(`
|
|
64
64
|
`))r!==""&&(t+=`[${n}]: ${r}
|
|
65
65
|
`);return t}var qc=class{figureToPaxF(e){const n=[];for(const t of e)n.push(t.toPax());return n}getFigures(e){const n={};for(const t in e){const r=this.figureToPaxF(e[t].mainList);n[t]=r}return n}getPaxJson(e,n,t){return{partName:n.partName,pDef:t,params:e,faces:this.getFigures(n.fig),volume:n.vol,subs:n.sub,log:n.logstr}}getPaxStr(e,n,t){const r=this.getPaxJson(e,n,t);return JSON.stringify(r,null,2)}};function dn(){return new qc}function Ji(e){let n=6;return e===1?n=0:e===2&&(n=1),n}function Qi(e,n,t,r){let s=Math.PI/2;n<2*t&&(s=2*Math.asin(n/(2*t)));const i=Math.min(e,s),o=Math.ceil(r/i),u=r/o;return[o,u]}function eo(e,n,t,r=Math.PI/6,s=2){const[i,o]=Qi(r,s,t,2*Math.PI),u=[];for(let c=0;c<i;c++){const h=e+t*Math.cos(c*o),m=n+t*Math.sin(c*o);u.push([h,m])}const a=u[0][0],f=u[0][1];return u.push([a,f]),u}function to(e,n,t,r,s,i,o=Math.PI/6,u=2){const a=Er(r,s,i),[f,c]=Qi(o,u,t,Math.abs(a)),h=i?c:-c,m=f+1,x=[];for(let b=1;b<m;b++){const l=r+b*h,d=e+t*Math.cos(l),p=n+t*Math.sin(l);x.push([d,p])}return x}var no=Math.PI/8,ro=20;function Ks(e,n){return[[e,n]]}function Vc(e,n,t,r,s,i){return to(e,n,t,r,s,i,no,ro)}function Gc(e,n,t){return eo(e,n,t,no,ro)}function Wc(e){const n=[];let t=0,r=0;for(const s of e){if(s.typ===0)n.push(...Ks(s.px,s.py));else if(s.typ===1)n.push(...Ks(s.px,s.py));else if(s.typ===2)try{const i=s,o=new et(Ji(i.typ),i.px,i.py,i.radius,i.large,i.ccw),u=vt(t,r,o);n.push(...Vc(u.pc.cx,u.pc.cy,o.radius,u.a1,u.a2,u.arcCcw))}catch(i){console.log("err730: "+i)}t=s.px,r=s.py}return n}function zs(e){return e.toFixed(4)}var Hc=class{constructor(){I(this,"pts");I(this,"ptIdx");I(this,"idx");this.pts=[],this.ptIdx=[],this.idx=0}addContour(e){const n=[],t=[];for(const i of e){const[o,u]=i;n.push(`[ ${zs(o)}, ${zs(u)} ]`),t.push(` ${this.idx}`),this.idx+=1}const r=`[ ${n.join(",")} ]`,s=`[ ${t.join(",")} ]`;this.pts.push(r),this.ptIdx.push(s)}getFigure(e){let n="";const t=[],r=[];for(const o of this.pts.keys()){const u=`ca_${e}_${o}`,a=`cb_${e}_${o}`;n+=`${u} = ${this.pts[o]};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var ve=Object.defineProperty;var $e=(s,t,u)=>t in s?ve(s,t,{enumerable:!0,configurable:!0,writable:!0,value:u}):s[t]=u;var J=(s,t,u)=>($e(s,typeof t!="symbol"?t+"":t,u),u);import{p as e,a as W,b as St,c as xt,i as ut,d as wt,f as S,g as U,E as p,h as nt,j as Lt,k as Ht,l as Dt,m as v,n as lt,t as mt,r as at,o as we,q as Me,s as K,u as gt,v as vt,w as B,x as ht,y as It,z as Bt,A as Ot,S as kt,B as be}from"./index.
|
|
1
|
+
var ve=Object.defineProperty;var $e=(s,t,u)=>t in s?ve(s,t,{enumerable:!0,configurable:!0,writable:!0,value:u}):s[t]=u;var J=(s,t,u)=>($e(s,typeof t!="symbol"?t+"":t,u),u);import{p as e,a as W,b as St,c as xt,i as ut,d as wt,f as S,g as U,E as p,h as nt,j as Lt,k as Ht,l as Dt,m as v,n as lt,t as mt,r as at,o as we,q as Me,s as K,u as gt,v as vt,w as B,x as ht,y as It,z as Bt,A as Ot,S as kt,B as be}from"./index.FRem4NB_.js";var ke=class{constructor(s,t,u,o,n){J(this,"base_center_x");J(this,"base_center_y");J(this,"base_radius");J(this,"initial_angle");J(this,"right_nleft");this.base_center_x=s,this.base_center_y=t,this.base_radius=u,this.initial_angle=o,this.right_nleft=n}angleSign(){return this.right_nleft?1:-1}lFromU(s){return this.base_radius*Math.sqrt(1+s**2)}wFromU(s){if(s<0)throw`err729: involute parameter au ${s} is negative`;if(Math.abs(s)>Math.PI/2)throw`err730: involute parameter au ${s} is larger than PI/2`;return this.angleSign()*(s-Math.atan(s))}w2FromU(s){return this.initial_angle+this.wFromU(s)}ptc(s){const t=this.lFromU(s),u=this.w2FromU(s),o=this.base_center_x+Math.cos(u)*t,n=this.base_center_y+Math.sin(u)*t;return[o,n]}ptcta(s){return this.initial_angle+this.angleSign()*s}uFromL(s){return Math.sqrt(s**2/this.base_radius**2-1)}uFromWslow(s){let u=Math.PI/3,o=u/2,n=this.wFromU(u),g=0;for(;Math.abs(n-s)>1e-4;)n<s?u+=o:u-=o,n=this.wFromU(u),o=o/2,g+=1;return console.log(`dbg072: uFromWslow itcnt ${g}`),u}laptc(s,t,u,o){if(Math.sign(t)*this.angleSign()<0)throw`err904: Invole.laptc angle-of-pressure ${t} not compatible with right_nleft ${this.right_nleft}`;const n=s+t,g=this.base_center_x+Math.cos(n)*this.base_radius,i=this.base_center_y+Math.sin(n)*this.base_radius,c=n-this.angleSign()*Math.PI/2,d=u*this.base_radius,a=g+Math.cos(c)*d,h=i+Math.sin(c)*d,r=this.lFromU(u)*o,l=u,_=Math.cos(l)*r,L=Math.sin(l)*r;return[a,h,_,L]}};function $t(s,t,u,o,n){return new ke(s,t,u,o,n)}var Ee=class{constructor(){J(this,"mod",1);J(this,"TN",23);J(this,"as",1);J(this,"cx",0);J(this,"cy",0);J(this,"brr",50);J(this,"blr",50);J(this,"ar",54);J(this,"pr",53);J(this,"dr",52);J(this,"br",51);J(this,"bRound",1);J(this,"adt",.5);J(this,"initAngle",0);J(this,"axisAngle",0);J(this,"involArcPairs",1);J(this,"skinThickness",0);J(this,"involuteR",$t(0,0,50,0,!0));J(this,"involuteL",$t(0,0,50,0,!1));J(this,"rud",0);J(this,"rup",0);J(this,"rua",0);J(this,"rwd",0);J(this,"rwp",0);J(this,"rwa",0);J(this,"lud",0);J(this,"lup",0);J(this,"lua",0);J(this,"lwd",0);J(this,"lwp",0);J(this,"lwa",0);J(this,"msg");J(this,"initStep",0);this.mod=1,this.msg="",this.initStep=0}incInitStep(s){if(this.initStep+1!==s)throw`err834: incInitStep initStep ${this.initStep} and target ${s} are not compatible`;this.initStep=s}checkInitStep(s,t){if(this.initStep<s)throw`err835: checkInitStep for ${t} initStep ${this.initStep} is too small compare to targetMin ${s}`}set1ModuleToothNumber(s,t){this.incInitStep(1),this.mod=s,this.TN=t,this.pr=this.mod*this.TN/2,this.as=2*Math.PI/this.TN}set2CenterPosition(s,t){this.incInitStep(2),this.cx=s,this.cy=t}set3CircleRadius(s,t,u,o){this.incInitStep(3),this.ar=this.pr+this.mod*s,this.dr=this.pr-this.mod*t,this.br=this.dr-this.mod*u,this.bRound=o}set4BaseCircles(s,t){this.incInitStep(4),this.brr=s,this.blr=t}set5AddendumThickness(s){this.incInitStep(5),this.adt=s/100}set6Angles(s,t){this.incInitStep(6),this.initAngle=s,this.axisAngle=t}set7InvoluteDetails(s,t){this.incInitStep(7),this.involArcPairs=s,this.skinThickness=t}getRefCircles(){return this.checkInitStep(4,"getRefCircles"),[v(this.cx,this.cy,this.ar,"Azure"),v(this.cx,this.cy,this.pr,"Azure"),v(this.cx,this.cy,this.dr,"Azure"),v(this.cx,this.cy,this.br,"Azure"),v(this.cx,this.cy,this.brr,"CornFlowerBlue"),v(this.cx,this.cy,this.blr,"Crimson")]}calcInvoluteAngles(){this.checkInitStep(4,"calcInvoluteAngles"),this.involuteR=$t(this.cx,this.cy,this.brr,0,!0),this.dr>this.brr?this.rud=this.involuteR.uFromL(this.dr):this.rud=0,this.rup=this.involuteR.uFromL(this.pr),this.rua=this.involuteR.uFromL(this.ar),this.rwd=this.involuteR.wFromU(this.rud),this.rwp=this.involuteR.wFromU(this.rup),this.rwa=this.involuteR.wFromU(this.rua),this.involuteL=$t(this.cx,this.cy,this.blr,0,!1),this.dr>this.blr?this.lud=this.involuteL.uFromL(this.dr):this.rud=0,this.lup=this.involuteL.uFromL(this.pr),this.lua=this.involuteL.uFromL(this.ar),this.lwd=this.involuteL.wFromU(this.lud),this.lwp=this.involuteL.wFromU(this.lup),this.lwa=this.involuteL.wFromU(this.lua)}checkProfileConditions(){const s=this.as*this.adt,t=this.rwa-this.rwp,u=Math.abs(this.lwa-this.lwp),o=s-t-u;if(o<0)throw`err554: No remaining Addendum reserve ${S(o)}
|
|
2
2
|
`;const n=this.as*(1-this.adt),g=this.rwp-this.rwd,i=Math.abs(this.lwp-this.lwd),c=n-g-i;if(c<2*Math.atan2(this.bRound,this.br))throw`err555: No remaining Dedendum reserve ${S(c)} compare to bRound ${S(this.bRound)}
|
|
3
3
|
`}getToothRef(){const s=6*this.involArcPairs,t=0;this.checkInitStep(7,"getProfile"),this.calcInvoluteAngles();const u=(this.rua-this.rud)/s,o=(this.lua-this.lud)/s,n=this.initAngle+t*this.as,g=$t(this.cx,this.cy,this.brr,n-this.rwp,!0),[i,c]=g.ptc(this.rud+0*u),d=U(i,c,"Gold");for(let f=0;f<s;f++){const[r,l]=g.ptc(this.rud+(f+1)*u);d.addSegStrokeA(r,l)}const a=n+this.as*this.adt,h=$t(this.cx,this.cy,this.blr,a-this.lwp,!1);for(let f=0;f<s+1;f++){const[r,l]=h.ptc(this.lud+(s-f)*o);d.addSegStrokeA(r,l)}return d.closeSegStroke(),d}getProfile(){this.checkInitStep(7,"getProfile"),this.calcInvoluteAngles(),this.checkProfileConditions();const s=this.rwd-this.rwp,t=this.lwd-this.lwp,u=this.dr>this.brr?this.dr:this.brr,o=this.dr>this.blr?this.dr:this.blr;if(this.bRound>u-this.br)throw`err409: getProfile bRound ${S(this.bRound)} too large for erdr ${S(u)} and br ${S(this.br)}`;if(this.bRound>o-this.br)throw`err408: getProfile bRound ${S(this.bRound)} too large for eldr ${S(o)} and br ${S(this.br)}`;const n=(this.rua-this.rud)/this.involArcPairs,g=(this.lua-this.lud)/this.involArcPairs,i=lt(this.cx,this.cy),c=i.translatePolar(this.initAngle+s,this.br),d=U(c.cx,c.cy);for(let a=0;a<this.TN;a++){const h=this.initAngle+a*this.as,f=i.translatePolar(h+s,this.br);d.addSegStrokeA(f.cx,f.cy).addCornerRounded(this.bRound);const r=$t(this.cx,this.cy,this.brr,h-this.rwp,!0),[l,_]=r.ptc(this.rud),L=r.ptcta(this.rud),D=lt(l,_).translatePolar(L-Math.PI/2,this.skinThickness);d.addSegStrokeA(D.cx,D.cy);for(let M=0;M<this.involArcPairs;M++){const G=this.rud+M*n,[x,C]=r.ptc(G+n),Z=r.ptcta(G),m=r.ptcta(G+n)+Math.PI,R=lt(x,C).translatePolar(Z-Math.PI/2,this.skinThickness);d.addPointA(R.cx,R.cy).addSeg2Arcs(Z,m)}const A=h+this.as*this.adt,w=$t(this.cx,this.cy,this.blr,A-this.lwp,!1),H=this.lud+this.involArcPairs*g,[k,$]=w.ptc(H),P=w.ptcta(H)+Math.PI,b=lt(k,$).translatePolar(P-Math.PI/2,this.skinThickness);d.addSegStrokeA(b.cx,b.cy);for(let M=0;M<this.involArcPairs;M++){const G=this.lud+(this.involArcPairs-M)*g,[x,C]=w.ptc(G-g),Z=w.ptcta(G)+Math.PI,m=w.ptcta(G-g),R=lt(x,C).translatePolar(Z-Math.PI/2,this.skinThickness);d.addPointA(R.cx,R.cy).addSeg2Arcs(Z,m)}const V=i.translatePolar(A+t,this.br);d.addSegStrokeA(V.cx,V.cy).addCornerRounded(this.bRound)}return d.closeSegStroke(),d}getMsg(){return this.msg}};function Zt(){return new Ee}function Ae(s,t,u,o){s.checkInitStep(1,"helper.gw2center-1"),t.checkInitStep(1,"helper.gw2center-2");const n=s.pr+t.pr+o,g=s.cx+n*Math.cos(u),i=s.cy+n*Math.sin(u);return[g,i,n]}function Re(s,t,u,o,n,g,i,c,d){s.checkInitStep(3,"helper.baseCircles-1"),t.checkInitStep(3,"helper.baseCircles-2");let a=u,h=n,f=o,r=g;const l=c,_=d;return l===0&&(t.TN>s.TN?(a=s.dr,h=a*t.TN/s.TN):(h=t.dr,a=h*s.TN/t.TN)),_===0&&(t.TN>s.TN?(f=s.dr,r=f*t.TN/s.TN):(r=t.dr,f=r*s.TN/t.TN)),i===1&&(f=a,r=h),[a,f,h,r]}var Ne=class{constructor(s,t,u,o,n,g){J(this,"gw1");J(this,"gw2");J(this,"initAngle1");J(this,"angleCenterCenter");J(this,"interAxis");J(this,"rightLeftCenter2");J(this,"msg");J(this,"apr");J(this,"apl");J(this,"lBDr",0);J(this,"lBDl",0);J(this,"laStartRr1",0);J(this,"laStartRr2",0);J(this,"laStartRl1",0);J(this,"laStartRl2",0);J(this,"aFODr1",0);J(this,"aFODr2",0);J(this,"aFODl1",0);J(this,"aFODl2",0);J(this,"lasr1",0);J(this,"lasr2",0);J(this,"lasl1",0);J(this,"lasl2",0);J(this,"firstToothUr1",0);J(this,"firstToothUl1",0);J(this,"ftdr1",0);J(this,"ftdl1",0);this.gw1=s,this.gw2=t,this.initAngle1=u,this.angleCenterCenter=o,this.interAxis=n,this.rightLeftCenter2=g,this.msg="",this.apr=0,this.apl=0}check1(){this.gw1.checkInitStep(4,"ActionLine.check1-1"),this.gw2.checkInitStep(4,"ActionLine.check1-2"),this.interAxis>this.gw1.ar+this.gw2.ar&&(this.msg+=`warn333: initAngle2 interAxis ${S(this.interAxis)} is too large compare to gw1.ar ${S(this.gw1.ar)} and gw2.ar ${S(this.gw2.ar)}
|
|
4
4
|
`),ht(this.gw1.brr*this.gw2.TN-this.gw2.brr*this.gw1.TN)!==0&&(this.msg+=`warn407: right ratios differ N1/N2 = ${this.gw1.TN} / ${this.gw2.TN} = ${S(this.gw1.TN/this.gw2.TN)} and brr1/brr2 = ${S(this.gw1.brr)}/${S(this.gw2.brr)} = ${S(this.gw1.brr/this.gw2.brr)}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var s;const a=((s=globalThis.__sveltekit_1novllp)==null?void 0:s.base)??"";var l;const e=((l=globalThis.__sveltekit_1novllp)==null?void 0:l.assets)??a;export{e as a,a as b};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as e}from"./entry.
|
|
1
|
+
import{s as e}from"./entry.BFaAd9jL.js";const r=()=>{const s=e;return{page:{subscribe:s.page.subscribe},navigating:{subscribe:s.navigating.subscribe},updated:s.updated}},b={subscribe(s){return r().page.subscribe(s)}};export{b as p};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__fileDeps=["_app/immutable/nodes/0.
|
|
2
|
-
import{s as N,a as U,p as h,g as j,i as b,f as p,q as B,r as W,e as z,c as F,b as G,m as S,u as m,t as H,d as J,j as K,v as A,w as k,x as Q}from"../chunks/scheduler.2BOoCPD3.js";import{S as X,i as Y,t as g,c as L,a as w,g as R,b as v,d as D,m as E,e as y}from"../chunks/index.BugmtA6_.js";const Z="modulepreload",M=function(a){return"/"+a},I={},P=function(e,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const f=document.querySelector("meta[property=csp-nonce]"),t=(f==null?void 0:f.nonce)||(f==null?void 0:f.getAttribute("nonce"));s=Promise.all(n.map(i=>{if(i=M(i),i in I)return;I[i]=!0;const l=i.endsWith(".css"),u=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${u}`))return;const o=document.createElement("link");if(o.rel=l?"stylesheet":Z,l||(o.as="script",o.crossOrigin=""),o.href=i,t&&o.setAttribute("nonce",t),document.head.appendChild(o),l)return new Promise((_,d)=>{o.addEventListener("load",_),o.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${i}`)))})}))}return s.then(()=>e()).catch(f=>{const t=new Event("vite:preloadError",{cancelable:!0});if(t.payload=f,window.dispatchEvent(t),!t.defaultPrevented)throw f})},re={};function $(a){let e,n,r;var s=a[1][0];function f(t,i){return{props:{data:t[3],form:t[2]}}}return s&&(e=k(s,f(a)),a[12](e)),{c(){e&&v(e.$$.fragment),n=h()},l(t){e&&D(e.$$.fragment,t),n=h()},m(t,i){e&&E(e,t,i),b(t,n,i),r=!0},p(t,i){if(i&2&&s!==(s=t[1][0])){if(e){R();const l=e;g(l.$$.fragment,1,0,()=>{y(l,1)}),L()}s?(e=k(s,f(t)),t[12](e),v(e.$$.fragment),w(e.$$.fragment,1),E(e,n.parentNode,n)):e=null}else if(s){const l={};i&8&&(l.data=t[3]),i&4&&(l.form=t[2]),e.$set(l)}},i(t){r||(e&&w(e.$$.fragment,t),r=!0)},o(t){e&&g(e.$$.fragment,t),r=!1},d(t){t&&p(n),a[12](null),e&&y(e,t)}}}function x(a){let e,n,r;var s=a[1][0];function f(t,i){return{props:{data:t[3],$$slots:{default:[ee]},$$scope:{ctx:t}}}}return s&&(e=k(s,f(a)),a[11](e)),{c(){e&&v(e.$$.fragment),n=h()},l(t){e&&D(e.$$.fragment,t),n=h()},m(t,i){e&&E(e,t,i),b(t,n,i),r=!0},p(t,i){if(i&2&&s!==(s=t[1][0])){if(e){R();const l=e;g(l.$$.fragment,1,0,()=>{y(l,1)}),L()}s?(e=k(s,f(t)),t[11](e),v(e.$$.fragment),w(e.$$.fragment,1),E(e,n.parentNode,n)):e=null}else if(s){const l={};i&8&&(l.data=t[3]),i&8215&&(l.$$scope={dirty:i,ctx:t}),e.$set(l)}},i(t){r||(e&&w(e.$$.fragment,t),r=!0)},o(t){e&&g(e.$$.fragment,t),r=!1},d(t){t&&p(n),a[11](null),e&&y(e,t)}}}function ee(a){let e,n,r;var s=a[1][1];function f(t,i){return{props:{data:t[4],form:t[2]}}}return s&&(e=k(s,f(a)),a[10](e)),{c(){e&&v(e.$$.fragment),n=h()},l(t){e&&D(e.$$.fragment,t),n=h()},m(t,i){e&&E(e,t,i),b(t,n,i),r=!0},p(t,i){if(i&2&&s!==(s=t[1][1])){if(e){R();const l=e;g(l.$$.fragment,1,0,()=>{y(l,1)}),L()}s?(e=k(s,f(t)),t[10](e),v(e.$$.fragment),w(e.$$.fragment,1),E(e,n.parentNode,n)):e=null}else if(s){const l={};i&16&&(l.data=t[4]),i&4&&(l.form=t[2]),e.$set(l)}},i(t){r||(e&&w(e.$$.fragment,t),r=!0)},o(t){e&&g(e.$$.fragment,t),r=!1},d(t){t&&p(n),a[10](null),e&&y(e,t)}}}function O(a){let e,n=a[6]&&T(a);return{c(){e=z("div"),n&&n.c(),this.h()},l(r){e=F(r,"DIV",{id:!0,"aria-live":!0,"aria-atomic":!0,style:!0});var s=G(e);n&&n.l(s),s.forEach(p),this.h()},h(){S(e,"id","svelte-announcer"),S(e,"aria-live","assertive"),S(e,"aria-atomic","true"),m(e,"position","absolute"),m(e,"left","0"),m(e,"top","0"),m(e,"clip","rect(0 0 0 0)"),m(e,"clip-path","inset(50%)"),m(e,"overflow","hidden"),m(e,"white-space","nowrap"),m(e,"width","1px"),m(e,"height","1px")},m(r,s){b(r,e,s),n&&n.m(e,null)},p(r,s){r[6]?n?n.p(r,s):(n=T(r),n.c(),n.m(e,null)):n&&(n.d(1),n=null)},d(r){r&&p(e),n&&n.d()}}}function T(a){let e;return{c(){e=H(a[7])},l(n){e=J(n,a[7])},m(n,r){b(n,e,r)},p(n,r){r&128&&K(e,n[7])},d(n){n&&p(e)}}}function te(a){let e,n,r,s,f;const t=[x,$],i=[];function l(o,_){return o[1][1]?0:1}e=l(a),n=i[e]=t[e](a);let u=a[5]&&O(a);return{c(){n.c(),r=U(),u&&u.c(),s=h()},l(o){n.l(o),r=j(o),u&&u.l(o),s=h()},m(o,_){i[e].m(o,_),b(o,r,_),u&&u.m(o,_),b(o,s,_),f=!0},p(o,[_]){let d=e;e=l(o),e===d?i[e].p(o,_):(R(),g(i[d],1,1,()=>{i[d]=null}),L(),n=i[e],n?n.p(o,_):(n=i[e]=t[e](o),n.c()),w(n,1),n.m(r.parentNode,r)),o[5]?u?u.p(o,_):(u=O(o),u.c(),u.m(s.parentNode,s)):u&&(u.d(1),u=null)},i(o){f||(w(n),f=!0)},o(o){g(n),f=!1},d(o){o&&(p(r),p(s)),i[e].d(o),u&&u.d(o)}}}function ne(a,e,n){let{stores:r}=e,{page:s}=e,{constructors:f}=e,{components:t=[]}=e,{form:i}=e,{data_0:l=null}=e,{data_1:u=null}=e;B(r.page.notify);let o=!1,_=!1,d=null;W(()=>{const c=r.page.subscribe(()=>{o&&(n(6,_=!0),Q().then(()=>{n(7,d=document.title||"untitled page")}))});return n(5,o=!0),c});function V(c){A[c?"unshift":"push"](()=>{t[1]=c,n(0,t)})}function q(c){A[c?"unshift":"push"](()=>{t[0]=c,n(0,t)})}function C(c){A[c?"unshift":"push"](()=>{t[0]=c,n(0,t)})}return a.$$set=c=>{"stores"in c&&n(8,r=c.stores),"page"in c&&n(9,s=c.page),"constructors"in c&&n(1,f=c.constructors),"components"in c&&n(0,t=c.components),"form"in c&&n(2,i=c.form),"data_0"in c&&n(3,l=c.data_0),"data_1"in c&&n(4,u=c.data_1)},a.$$.update=()=>{a.$$.dirty&768&&r.page.set(s)},[t,f,i,l,u,o,_,d,r,s,V,q,C]}class oe extends X{constructor(e){super(),Y(this,e,ne,te,N,{stores:8,page:9,constructors:1,components:0,form:2,data_0:3,data_1:4})}}const ae=[()=>P(()=>import("../nodes/0.
|
|
1
|
+
const __vite__fileDeps=["_app/immutable/nodes/0.CsAWk4mK.js","_app/immutable/chunks/scheduler.2BOoCPD3.js","_app/immutable/chunks/index.BugmtA6_.js","_app/immutable/chunks/index.FRem4NB_.js","_app/immutable/chunks/paths.CmHCI0tQ.js","_app/immutable/assets/0.BNk8pMG6.css","_app/immutable/nodes/1.DDwhwPCl.js","_app/immutable/chunks/stores.CNgkQH-j.js","_app/immutable/chunks/entry.BFaAd9jL.js","_app/immutable/nodes/2.1cPiKGbF.js","_app/immutable/chunks/makeList.D9WwT8E8.js","_app/immutable/assets/2.CTp7BhB8.css","_app/immutable/nodes/3.BlyuNevc.js","_app/immutable/assets/3.Bup7ghXO.css"],__vite__mapDeps=i=>i.map(i=>__vite__fileDeps[i]);
|
|
2
|
+
import{s as N,a as U,p as h,g as j,i as b,f as p,q as B,r as W,e as z,c as F,b as G,m as S,u as m,t as H,d as J,j as K,v as A,w as k,x as Q}from"../chunks/scheduler.2BOoCPD3.js";import{S as X,i as Y,t as g,c as L,a as w,g as R,b as v,d as D,m as E,e as y}from"../chunks/index.BugmtA6_.js";const Z="modulepreload",M=function(a){return"/"+a},I={},P=function(e,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const f=document.querySelector("meta[property=csp-nonce]"),t=(f==null?void 0:f.nonce)||(f==null?void 0:f.getAttribute("nonce"));s=Promise.all(n.map(i=>{if(i=M(i),i in I)return;I[i]=!0;const l=i.endsWith(".css"),u=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${u}`))return;const o=document.createElement("link");if(o.rel=l?"stylesheet":Z,l||(o.as="script",o.crossOrigin=""),o.href=i,t&&o.setAttribute("nonce",t),document.head.appendChild(o),l)return new Promise((_,d)=>{o.addEventListener("load",_),o.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${i}`)))})}))}return s.then(()=>e()).catch(f=>{const t=new Event("vite:preloadError",{cancelable:!0});if(t.payload=f,window.dispatchEvent(t),!t.defaultPrevented)throw f})},re={};function $(a){let e,n,r;var s=a[1][0];function f(t,i){return{props:{data:t[3],form:t[2]}}}return s&&(e=k(s,f(a)),a[12](e)),{c(){e&&v(e.$$.fragment),n=h()},l(t){e&&D(e.$$.fragment,t),n=h()},m(t,i){e&&E(e,t,i),b(t,n,i),r=!0},p(t,i){if(i&2&&s!==(s=t[1][0])){if(e){R();const l=e;g(l.$$.fragment,1,0,()=>{y(l,1)}),L()}s?(e=k(s,f(t)),t[12](e),v(e.$$.fragment),w(e.$$.fragment,1),E(e,n.parentNode,n)):e=null}else if(s){const l={};i&8&&(l.data=t[3]),i&4&&(l.form=t[2]),e.$set(l)}},i(t){r||(e&&w(e.$$.fragment,t),r=!0)},o(t){e&&g(e.$$.fragment,t),r=!1},d(t){t&&p(n),a[12](null),e&&y(e,t)}}}function x(a){let e,n,r;var s=a[1][0];function f(t,i){return{props:{data:t[3],$$slots:{default:[ee]},$$scope:{ctx:t}}}}return s&&(e=k(s,f(a)),a[11](e)),{c(){e&&v(e.$$.fragment),n=h()},l(t){e&&D(e.$$.fragment,t),n=h()},m(t,i){e&&E(e,t,i),b(t,n,i),r=!0},p(t,i){if(i&2&&s!==(s=t[1][0])){if(e){R();const l=e;g(l.$$.fragment,1,0,()=>{y(l,1)}),L()}s?(e=k(s,f(t)),t[11](e),v(e.$$.fragment),w(e.$$.fragment,1),E(e,n.parentNode,n)):e=null}else if(s){const l={};i&8&&(l.data=t[3]),i&8215&&(l.$$scope={dirty:i,ctx:t}),e.$set(l)}},i(t){r||(e&&w(e.$$.fragment,t),r=!0)},o(t){e&&g(e.$$.fragment,t),r=!1},d(t){t&&p(n),a[11](null),e&&y(e,t)}}}function ee(a){let e,n,r;var s=a[1][1];function f(t,i){return{props:{data:t[4],form:t[2]}}}return s&&(e=k(s,f(a)),a[10](e)),{c(){e&&v(e.$$.fragment),n=h()},l(t){e&&D(e.$$.fragment,t),n=h()},m(t,i){e&&E(e,t,i),b(t,n,i),r=!0},p(t,i){if(i&2&&s!==(s=t[1][1])){if(e){R();const l=e;g(l.$$.fragment,1,0,()=>{y(l,1)}),L()}s?(e=k(s,f(t)),t[10](e),v(e.$$.fragment),w(e.$$.fragment,1),E(e,n.parentNode,n)):e=null}else if(s){const l={};i&16&&(l.data=t[4]),i&4&&(l.form=t[2]),e.$set(l)}},i(t){r||(e&&w(e.$$.fragment,t),r=!0)},o(t){e&&g(e.$$.fragment,t),r=!1},d(t){t&&p(n),a[10](null),e&&y(e,t)}}}function O(a){let e,n=a[6]&&T(a);return{c(){e=z("div"),n&&n.c(),this.h()},l(r){e=F(r,"DIV",{id:!0,"aria-live":!0,"aria-atomic":!0,style:!0});var s=G(e);n&&n.l(s),s.forEach(p),this.h()},h(){S(e,"id","svelte-announcer"),S(e,"aria-live","assertive"),S(e,"aria-atomic","true"),m(e,"position","absolute"),m(e,"left","0"),m(e,"top","0"),m(e,"clip","rect(0 0 0 0)"),m(e,"clip-path","inset(50%)"),m(e,"overflow","hidden"),m(e,"white-space","nowrap"),m(e,"width","1px"),m(e,"height","1px")},m(r,s){b(r,e,s),n&&n.m(e,null)},p(r,s){r[6]?n?n.p(r,s):(n=T(r),n.c(),n.m(e,null)):n&&(n.d(1),n=null)},d(r){r&&p(e),n&&n.d()}}}function T(a){let e;return{c(){e=H(a[7])},l(n){e=J(n,a[7])},m(n,r){b(n,e,r)},p(n,r){r&128&&K(e,n[7])},d(n){n&&p(e)}}}function te(a){let e,n,r,s,f;const t=[x,$],i=[];function l(o,_){return o[1][1]?0:1}e=l(a),n=i[e]=t[e](a);let u=a[5]&&O(a);return{c(){n.c(),r=U(),u&&u.c(),s=h()},l(o){n.l(o),r=j(o),u&&u.l(o),s=h()},m(o,_){i[e].m(o,_),b(o,r,_),u&&u.m(o,_),b(o,s,_),f=!0},p(o,[_]){let d=e;e=l(o),e===d?i[e].p(o,_):(R(),g(i[d],1,1,()=>{i[d]=null}),L(),n=i[e],n?n.p(o,_):(n=i[e]=t[e](o),n.c()),w(n,1),n.m(r.parentNode,r)),o[5]?u?u.p(o,_):(u=O(o),u.c(),u.m(s.parentNode,s)):u&&(u.d(1),u=null)},i(o){f||(w(n),f=!0)},o(o){g(n),f=!1},d(o){o&&(p(r),p(s)),i[e].d(o),u&&u.d(o)}}}function ne(a,e,n){let{stores:r}=e,{page:s}=e,{constructors:f}=e,{components:t=[]}=e,{form:i}=e,{data_0:l=null}=e,{data_1:u=null}=e;B(r.page.notify);let o=!1,_=!1,d=null;W(()=>{const c=r.page.subscribe(()=>{o&&(n(6,_=!0),Q().then(()=>{n(7,d=document.title||"untitled page")}))});return n(5,o=!0),c});function V(c){A[c?"unshift":"push"](()=>{t[1]=c,n(0,t)})}function q(c){A[c?"unshift":"push"](()=>{t[0]=c,n(0,t)})}function C(c){A[c?"unshift":"push"](()=>{t[0]=c,n(0,t)})}return a.$$set=c=>{"stores"in c&&n(8,r=c.stores),"page"in c&&n(9,s=c.page),"constructors"in c&&n(1,f=c.constructors),"components"in c&&n(0,t=c.components),"form"in c&&n(2,i=c.form),"data_0"in c&&n(3,l=c.data_0),"data_1"in c&&n(4,u=c.data_1)},a.$$.update=()=>{a.$$.dirty&768&&r.page.set(s)},[t,f,i,l,u,o,_,d,r,s,V,q,C]}class oe extends X{constructor(e){super(),Y(this,e,ne,te,N,{stores:8,page:9,constructors:1,components:0,form:2,data_0:3,data_1:4})}}const ae=[()=>P(()=>import("../nodes/0.CsAWk4mK.js"),__vite__mapDeps([0,1,2,3,4,5])),()=>P(()=>import("../nodes/1.DDwhwPCl.js"),__vite__mapDeps([6,1,2,7,8,4])),()=>P(()=>import("../nodes/2.1cPiKGbF.js"),__vite__mapDeps([9,1,3,2,10,4,11])),()=>P(()=>import("../nodes/3.BlyuNevc.js"),__vite__mapDeps([12,10,3,8,1,4,2,7,13]))],le=[],fe={"/":[2],"/[...design]":[3]},ce={handleError:({error:a})=>{console.error(a)},reroute:()=>{}};export{fe as dictionary,ce as hooks,re as matchers,ae as nodes,oe as root,le as server_loads};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as t}from"../chunks/entry.BFaAd9jL.js";export{t as start};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{s as Q,y as V,e as h,a as j,c as v,l as L,g as $,b as A,f as a,m as E,i as u,h as H,z as G,A as J,B as K,o as U,t as X,d as Y,n as Z}from"../chunks/scheduler.2BOoCPD3.js";import{S as ee,i as te,a as se,t as ie}from"../chunks/index.BugmtA6_.js";import{e as W,C as le}from"../chunks/index.
|
|
1
|
+
import{s as Q,y as V,e as h,a as j,c as v,l as L,g as $,b as A,f as a,m as E,i as u,h as H,z as G,A as J,B as K,o as U,t as X,d as Y,n as Z}from"../chunks/scheduler.2BOoCPD3.js";import{S as ee,i as te,a as se,t as ie}from"../chunks/index.BugmtA6_.js";import{e as W,C as le}from"../chunks/index.FRem4NB_.js";import{b as ne}from"../chunks/paths.CmHCI0tQ.js";const ae=!0,$e=Object.freeze(Object.defineProperty({__proto__:null,prerender:ae},Symbol.toStringTag,{value:"Module"})),re="designix-ui",oe="0.5.5",ce="The svelte-kit app built on top of designix",pe={type:"git",url:"git+https://github.com/charlyoleg2/parametrix.git"},ue="https://charlyoleg2.github.io/parametrix/",he="charlyoleg2",ve="ISC",de=["cad","programmatic","2D","circle","stroke","arc","gear"],fe="module",me={useTabs:!0,singleQuote:!0,trailingComma:"none",printWidth:100,plugins:["prettier-plugin-svelte"],overrides:[{files:"*.svelte",options:{parser:"svelte"}}]},ge={cp_pgdsvg:"shx cp -r ../../node_modules/designix/dist/pgdsvg static/",dev:"vite dev",build:"vite build",preview:"vite preview",check:"svelte-kit sync && svelte-check --tsconfig ./tsconfig.json","check:watch":"svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch","test:unit":"vitest","test:unit:once":"vitest --run",lint:"prettier --check . && eslint .",ci:"run-s cp_pgdsvg build lint check test:unit:once",format:"prettier --write .",clean:"shx rm -fr .svelte-kit build node_modules static/pgdsvg"},_e={designix:"^0.5.37",geometrix:"^0.5.36",geomui:"^0.5.38"},xe={"@sveltejs/adapter-auto":"^3.2.0","@sveltejs/adapter-static":"^3.0.1","@sveltejs/kit":"^2.5.7","@sveltejs/vite-plugin-svelte":"^3.1.0","@typescript-eslint/eslint-plugin":"^7.0.1","@typescript-eslint/parser":"^7.0.1",eslint:"^8.57.0","eslint-config-prettier":"^9.1.0","eslint-plugin-svelte":"^2.38.0","npm-run-all":"^4.1.5",prettier:"^3.2.5","prettier-plugin-svelte":"^3.2.3",sass:"^1.77.0",shx:"^0.3.4",svelte:"^4.2.16","svelte-check":"^3.7.1",tslib:"^2.6.2",typescript:"^5.4.5",vite:"^5.2.11",vitest:"^1.6.0"},ye={name:re,version:oe,description:ce,private:!0,repository:pe,homepage:ue,author:he,license:ve,keywords:de,type:fe,prettier:me,scripts:ge,dependencies:_e,devDependencies:xe};function q(c,i,p){const r=c.slice();return r[3]=i[p],r}function F(c){let i=c[3]+"",p,r;return{c(){p=X(i),r=h("br")},l(s){p=Y(s,i),r=v(s,"BR",{})},m(s,m){u(s,p,m),u(s,r,m)},p:Z,d(s){s&&(a(p),a(r))}}}function be(c){let i,p="Welcome to designix-ui",r,s,m=`Showcasing the usage of the <a href="https://svelte.dev/">svelte</a> library
|
|
2
2
|
<a href="https://www.npmjs.com/">geomui</a>.`,g,f,R=`<a href="${`${ne}/`}" class="svelte-im9xuh">index: list of designs</a>`,M,_,S,d,b,B=`<a href="https://github.com/charlyoleg2/parametrix">designix-ui</a>, a minimalist showcase
|
|
3
3
|
of
|
|
4
4
|
<a href="https://www.npmjs.com/">geomui</a>.`,D,x,k,N="Designix-ui version",O,w,C;const z=c[2].default,o=V(z,c,c[1],null);let T=W(c[0]),l=[];for(let e=0;e<T.length;e+=1)l[e]=F(q(c,T,e));return{c(){i=h("h1"),i.textContent=p,r=j(),s=h("h6"),s.innerHTML=m,g=j(),f=h("nav"),f.innerHTML=R,M=j(),_=h("main"),o&&o.c(),S=j(),d=h("footer"),b=h("article"),b.innerHTML=B,D=j(),x=h("article"),k=h("h3"),k.textContent=N,O=j(),w=h("code");for(let e=0;e<l.length;e+=1)l[e].c();this.h()},l(e){i=v(e,"H1",{class:!0,"data-svelte-h":!0}),L(i)!=="svelte-1ow6r3d"&&(i.textContent=p),r=$(e),s=v(e,"H6",{class:!0,"data-svelte-h":!0}),L(s)!=="svelte-7mn22s"&&(s.innerHTML=m),g=$(e),f=v(e,"NAV",{class:!0,"data-svelte-h":!0}),L(f)!=="svelte-ww4mf0"&&(f.innerHTML=R),M=$(e),_=v(e,"MAIN",{class:!0});var n=A(_);o&&o.l(n),n.forEach(a),S=$(e),d=v(e,"FOOTER",{class:!0});var t=A(d);b=v(t,"ARTICLE",{"data-svelte-h":!0}),L(b)!=="svelte-1pwhz7h"&&(b.innerHTML=B),D=$(t),x=v(t,"ARTICLE",{});var y=A(x);k=v(y,"H3",{"data-svelte-h":!0}),L(k)!=="svelte-18yz28i"&&(k.textContent=N),O=$(y),w=v(y,"CODE",{});var P=A(w);for(let I=0;I<l.length;I+=1)l[I].l(P);P.forEach(a),y.forEach(a),t.forEach(a),this.h()},h(){E(i,"class","svelte-im9xuh"),E(s,"class","svelte-im9xuh"),E(f,"class","svelte-im9xuh"),E(_,"class","svelte-im9xuh"),E(d,"class","svelte-im9xuh")},m(e,n){u(e,i,n),u(e,r,n),u(e,s,n),u(e,g,n),u(e,f,n),u(e,M,n),u(e,_,n),o&&o.m(_,null),u(e,S,n),u(e,d,n),H(d,b),H(d,D),H(d,x),H(x,k),H(x,O),H(x,w);for(let t=0;t<l.length;t+=1)l[t]&&l[t].m(w,null);C=!0},p(e,[n]){if(o&&o.p&&(!C||n&2)&&G(o,z,e,e[1],C?K(z,e[1],n,null):J(e[1]),null),n&1){T=W(e[0]);let t;for(t=0;t<T.length;t+=1){const y=q(e,T,t);l[t]?l[t].p(y,n):(l[t]=F(y),l[t].c(),l[t].m(w,null))}for(;t<l.length;t+=1)l[t].d(1);l.length=T.length}},i(e){C||(se(o,e),C=!0)},o(e){ie(o,e),C=!1},d(e){e&&(a(i),a(r),a(s),a(g),a(f),a(M),a(_),a(S),a(d)),o&&o.d(e),U(l,e)}}}function ke(c,i,p){let{$$slots:r={},$$scope:s}=i;const m=le(ye);return c.$$set=g=>{"$$scope"in g&&p(1,s=g.$$scope)},[m,s,r]}class He extends ee{constructor(i){super(),te(this,i,ke,be,Q,{})}}export{He as component,$e as universal};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as x,e as u,t as h,a as S,c as d,b as v,d as g,f as m,g as j,i as _,h as b,j as E,n as $,k}from"../chunks/scheduler.2BOoCPD3.js";import{S as q,i as y}from"../chunks/index.BugmtA6_.js";import{p as C}from"../chunks/stores.
|
|
1
|
+
import{s as x,e as u,t as h,a as S,c as d,b as v,d as g,f as m,g as j,i as _,h as b,j as E,n as $,k}from"../chunks/scheduler.2BOoCPD3.js";import{S as q,i as y}from"../chunks/index.BugmtA6_.js";import{p as C}from"../chunks/stores.CNgkQH-j.js";function H(i){var f;let a,s=i[0].status+"",r,o,n,p=((f=i[0].error)==null?void 0:f.message)+"",c;return{c(){a=u("h1"),r=h(s),o=S(),n=u("p"),c=h(p)},l(e){a=d(e,"H1",{});var t=v(a);r=g(t,s),t.forEach(m),o=j(e),n=d(e,"P",{});var l=v(n);c=g(l,p),l.forEach(m)},m(e,t){_(e,a,t),b(a,r),_(e,o,t),_(e,n,t),b(n,c)},p(e,[t]){var l;t&1&&s!==(s=e[0].status+"")&&E(r,s),t&1&&p!==(p=((l=e[0].error)==null?void 0:l.message)+"")&&E(c,p)},i:$,o:$,d(e){e&&(m(a),m(o),m(n))}}}function P(i,a,s){let r;return k(i,C,o=>s(0,r=o)),[r]}class B extends q{constructor(a){super(),y(this,a,P,H,x,{})}}export{B as component};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as g,e as _,a as x,c as d,l as b,g as y,b as p,f as c,m as v,i as f,n as m,o as C,t as L,d as k,h as u}from"../chunks/scheduler.2BOoCPD3.js";import{e as E}from"../chunks/index.
|
|
1
|
+
import{s as g,e as _,a as x,c as d,l as b,g as y,b as p,f as c,m as v,i as f,n as m,o as C,t as L,d as k,h as u}from"../chunks/scheduler.2BOoCPD3.js";import{e as E}from"../chunks/index.FRem4NB_.js";import{S,i as $}from"../chunks/index.BugmtA6_.js";import{d as q}from"../chunks/makeList.D9WwT8E8.js";import{b as A}from"../chunks/paths.CmHCI0tQ.js";function H(r,e,l){const o=r.slice();return o[0]=e[l],o}function I(r){let e,l,o;return{c(){e=_("li"),l=_("a"),o=L(r[0]),this.h()},l(a){e=d(a,"LI",{});var n=p(e);l=d(n,"A",{href:!0});var s=p(l);o=k(s,r[0]),s.forEach(c),n.forEach(c),this.h()},h(){v(l,"href",`${A}/${r[0]}`)},m(a,n){f(a,e,n),u(e,l),u(l,o)},p:m,d(a){a&&c(e)}}}function N(r){let e,l="List of designs:",o,a,n=E(q),s=[];for(let t=0;t<n.length;t+=1)s[t]=I(H(r,n,t));return{c(){e=_("h2"),e.textContent=l,o=x(),a=_("ol");for(let t=0;t<s.length;t+=1)s[t].c();this.h()},l(t){e=d(t,"H2",{class:!0,"data-svelte-h":!0}),b(e)!=="svelte-96cxme"&&(e.textContent=l),o=y(t),a=d(t,"OL",{});var h=p(a);for(let i=0;i<s.length;i+=1)s[i].l(h);h.forEach(c),this.h()},h(){v(e,"class","svelte-1r3d1r")},m(t,h){f(t,e,h),f(t,o,h),f(t,a,h);for(let i=0;i<s.length;i+=1)s[i]&&s[i].m(a,null)},p:m,i:m,o:m,d(t){t&&(c(e),c(o),c(a)),C(s,t)}}}class B extends S{constructor(e){super(),$(this,e,null,N,g,{})}}export{B as component};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as Pt,b as wl}from"../chunks/makeList.REsiyAUZ.js";import{H as Ol,w as ul,g as Cl}from"../chunks/entry.CCZQw5oO.js";import{Q as Dl,s as ze,p as st,i as J,n as Ue,f as k,e as _,c as p,b as S,R as ht,m as f,h as o,S as G,v as je,a as I,g as P,T as Pe,o as Xe,y as El,t as K,l as oe,d as q,U as Be,z as Ll,A as Sl,B as jl,j as ve,C as Ye,V as ke,k as at,r as Et,W as ml,X as _t,Y as Ot,Z as Il,H as bt,_ as ot,$ as Pl,a0 as Al}from"../chunks/scheduler.2BOoCPD3.js";import{S as Me,i as ye,f as Ae,b as De,d as Ee,m as Le,a as Te,t as we,e as Se,g as Ul,c as zl}from"../chunks/index.BugmtA6_.js";import{e as Ce,D as Ml,F as dl,G as yl,H as hl,I as _l,P as wt,J as Fl,K as Nt,L as ct,M as Bl,N as Rl,O as Ct,Q as Hl,R as At,f as dt,r as Dt,T as Ze,U as Vl,V as Wl,W as Xl,X as Yl,Y as Kl}from"../chunks/index.Bt0gWcKV.js";import{b as vt}from"../chunks/paths.BE-8toip.js";import{p as ql}from"../chunks/stores.DWbCP-9J.js";function Gl(t,e){throw new Ol(t,e)}new TextEncoder;function Zl({params:t}){const e=t.design;if(Object.keys(Pt).includes(e))return{pageDef:Pt[e],allLink:wl};Gl(404,"Design undefined!")}const vs=Object.freeze(Object.defineProperty({__proto__:null,load:Zl},Symbol.toStringTag,{value:"Module"})),Ke=ul({});function pl(t,e,l){const n=Dl(Ke);if(Object.keys(n).includes(t)){const s=n[t],a=Object.keys(s);for(const c of Object.keys(e))a.includes(c)?l&&(s[c]=e[c]):s[c]=e[c];n[t]=s}else n[t]=e;Ke.set(n)}function Jl(t){const e=t.pDef.partName,l={};for(const n of t.pDef.params)l[n.name]=n.init;pl(e,l,!1)}function Ut(t){let e,l,n,r,s,a,c;return{c(){e=_("aside"),l=_("div"),n=_("button"),r=_("img"),this.h()},l(u){e=p(u,"ASIDE",{class:!0});var i=S(e);l=p(i,"DIV",{class:!0});var m=S(l);n=p(m,"BUTTON",{class:!0});var h=S(n);r=p(h,"IMG",{src:!0,alt:!0}),h.forEach(k),m.forEach(k),i.forEach(k),this.h()},h(){ht(r.src,s=t[1])||f(r,"src",s),f(r,"alt",t[1]),f(n,"class","svelte-sjxf1e"),f(l,"class","dialog svelte-sjxf1e"),f(e,"class","backdrop svelte-sjxf1e")},m(u,i){J(u,e,i),o(e,l),o(l,n),o(n,r),a||(c=G(n,"click",t[2]),a=!0)},p(u,i){i&2&&!ht(r.src,s=u[1])&&f(r,"src",s),i&2&&f(r,"alt",u[1])},d(u){u&&k(e),a=!1,c()}}}function Ql(t){let e,l=t[0]&&Ut(t);return{c(){l&&l.c(),e=st()},l(n){l&&l.l(n),e=st()},m(n,r){l&&l.m(n,r),J(n,e,r)},p(n,[r]){n[0]?l?l.p(n,r):(l=Ut(n),l.c(),l.m(e.parentNode,e)):l&&(l.d(1),l=null)},i:Ue,o:Ue,d(n){n&&k(e),l&&l.d(n)}}}function $l(t,e,l){let{svgPath:n}=e,{modalOpen:r}=e;function s(){l(0,r=!1)}return t.$$set=a=>{"svgPath"in a&&l(1,n=a.svgPath),"modalOpen"in a&&l(0,r=a.modalOpen)},[r,n,s]}class gl extends Me{constructor(e){super(),ye(this,e,$l,Ql,ze,{svgPath:1,modalOpen:0})}}function zt(t,e,l){const n=t.slice();return n[8]=e[l],n}function Mt(t){let e,l,n,r,s,a,c;function u(){return t[6](t[8])}return{c(){e=_("button"),l=_("img"),s=I(),this.h()},l(i){e=p(i,"BUTTON",{class:!0});var m=S(e);l=p(m,"IMG",{src:!0,alt:!0,class:!0}),s=P(m),m.forEach(k),this.h()},h(){ht(l.src,n=t[8])||f(l,"src",n),f(l,"alt",r=t[8]),f(l,"class","svelte-fxmnfh"),f(e,"class","svelte-fxmnfh")},m(i,m){J(i,e,m),o(e,l),o(e,s),a||(c=G(e,"click",u),a=!0)},p(i,m){t=i,m&1&&!ht(l.src,n=t[8])&&f(l,"src",n),m&1&&r!==(r=t[8])&&f(l,"alt",r)},d(i){i&&k(e),a=!1,c()}}}function xl(t){let e,l,n,r,s;function a(m){t[5](m)}let c={svgPath:t[2]};t[1]!==void 0&&(c.modalOpen=t[1]),l=new gl({props:c}),je.push(()=>Ae(l,"modalOpen",a));let u=Ce(t[0]),i=[];for(let m=0;m<u.length;m+=1)i[m]=Mt(zt(t,u,m));return{c(){e=_("section"),De(l.$$.fragment),r=I();for(let m=0;m<i.length;m+=1)i[m].c();this.h()},l(m){e=p(m,"SECTION",{class:!0});var h=S(e);Ee(l.$$.fragment,h),r=P(h);for(let N=0;N<i.length;N+=1)i[N].l(h);h.forEach(k),this.h()},h(){f(e,"class","svelte-fxmnfh")},m(m,h){J(m,e,h),Le(l,e,null),o(e,r);for(let N=0;N<i.length;N+=1)i[N]&&i[N].m(e,null);s=!0},p(m,[h]){const N={};if(h&4&&(N.svgPath=m[2]),!n&&h&2&&(n=!0,N.modalOpen=m[1],Pe(()=>n=!1)),l.$set(N),h&9){u=Ce(m[0]);let v;for(v=0;v<u.length;v+=1){const d=zt(m,u,v);i[v]?i[v].p(d,h):(i[v]=Mt(d),i[v].c(),i[v].m(e,null))}for(;v<i.length;v+=1)i[v].d(1);i.length=u.length}},i(m){s||(Te(l.$$.fragment,m),s=!0)},o(m){we(l.$$.fragment,m),s=!1},d(m){m&&k(e),Se(l),Xe(i,m)}}}function en(t){const e=[];for(const l of Object.values(t.paramSvg))e.includes(l)||e.push(l);return e}function tn(t,e,l){let{pDef:n}=e;function r(h){const N=en(n),v=[];for(const d of N)v.push(`${vt}/pgdsvg/${d}`);return v}let s=[],a=!1,c;function u(h){l(2,c=h),l(1,a=!0)}function i(h){a=h,l(1,a)}const m=h=>u(h);return t.$$set=h=>{"pDef"in h&&l(4,n=h.pDef)},t.$$.update=()=>{t.$$.dirty&16&&l(0,s=r(n.partName))},[s,a,c,u,n,i,m]}class ln extends Me{constructor(e){super(),ye(this,e,tn,xl,ze,{pDef:4})}}function yt(t){let e,l,n,r,s,a,c="Cancel",u,i,m,h,N,v;const d=t[7].default,b=El(d,t,t[6],null);return{c(){e=_("aside"),l=_("div"),n=_("article"),b&&b.c(),r=I(),s=_("footer"),a=_("button"),a.textContent=c,u=I(),i=_("button"),m=K(t[1]),this.h()},l(T){e=p(T,"ASIDE",{class:!0});var g=S(e);l=p(g,"DIV",{class:!0});var O=S(l);n=p(O,"ARTICLE",{class:!0});var D=S(n);b&&b.l(D),D.forEach(k),r=P(O),s=p(O,"FOOTER",{class:!0});var C=S(s);a=p(C,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-hcvk9s"&&(a.textContent=c),u=P(C),i=p(C,"BUTTON",{class:!0});var z=S(i);m=q(z,t[1]),z.forEach(k),C.forEach(k),O.forEach(k),g.forEach(k),this.h()},h(){f(n,"class","question svelte-weruk7"),f(a,"class","cancel svelte-weruk7"),f(i,"class","ok svelte-weruk7"),f(s,"class","svelte-weruk7"),f(l,"class","dialog svelte-weruk7"),Be(l,"sizeLarge",t[2]),f(e,"class","backdrop svelte-weruk7")},m(T,g){J(T,e,g),o(e,l),o(l,n),b&&b.m(n,null),o(l,r),o(l,s),o(s,a),o(s,u),o(s,i),o(i,m),h=!0,N||(v=[G(a,"click",t[3]),G(i,"click",t[4])],N=!0)},p(T,g){b&&b.p&&(!h||g&64)&&Ll(b,d,T,T[6],h?jl(d,T[6],g,null):Sl(T[6]),null),(!h||g&2)&&ve(m,T[1]),(!h||g&4)&&Be(l,"sizeLarge",T[2])},i(T){h||(Te(b,T),h=!0)},o(T){we(b,T),h=!1},d(T){T&&k(e),b&&b.d(T),N=!1,Ye(v)}}}function nn(t){let e,l,n=t[0]&&yt(t);return{c(){n&&n.c(),e=st()},l(r){n&&n.l(r),e=st()},m(r,s){n&&n.m(r,s),J(r,e,s),l=!0},p(r,[s]){r[0]?n?(n.p(r,s),s&1&&Te(n,1)):(n=yt(r),n.c(),Te(n,1),n.m(e.parentNode,e)):n&&(Ul(),we(n,1,1,()=>{n=null}),zl())},i(r){l||(Te(n),l=!0)},o(r){we(n),l=!1},d(r){r&&k(e),n&&n.d(r)}}}function sn(t,e,l){let{$$slots:n={},$$scope:r}=e,{okName:s="Ok"}=e,{okFunc:a}=e,{modalOpen:c}=e,{sizeLarge:u=!1}=e;function i(){l(0,c=!1)}function m(){a(),l(0,c=!1)}return t.$$set=h=>{"okName"in h&&l(1,s=h.okName),"okFunc"in h&&l(5,a=h.okFunc),"modalOpen"in h&&l(0,c=h.modalOpen),"sizeLarge"in h&&l(2,u=h.sizeLarge),"$$scope"in h&&l(6,r=h.$$scope)},[c,s,u,i,m,a,r,n]}class gt extends Me{constructor(e){super(),ye(this,e,sn,nn,ze,{okName:1,okFunc:5,modalOpen:0,sizeLarge:2})}}function Ft(t,e,l){const n=t.slice();return n[17]=e[l],n[18]=e,n[19]=l,n}function Bt(t,e,l){const n=t.slice();return n[17]=e[l],n}function Rt(t){let e,l=t[17]+"",n;return{c(){e=_("p"),n=K(l),this.h()},l(r){e=p(r,"P",{class:!0});var s=S(e);n=q(s,l),s.forEach(k),this.h()},h(){f(e,"class","diagItem svelte-12dj9tj")},m(r,s){J(r,e,s),o(e,n)},p(r,s){s&1&&l!==(l=r[17]+"")&&ve(n,l)},d(r){r&&k(e)}}}function Ht(t){let e,l=t[3][t[17]]&&Rt(t);return{c(){l&&l.c(),e=st()},l(n){l&&l.l(n),e=st()},m(n,r){l&&l.m(n,r),J(n,e,r)},p(n,r){n[3][n[17]]?l?l.p(n,r):(l=Rt(n),l.c(),l.m(e.parentNode,e)):l&&(l.d(1),l=null)},d(n){n&&k(e),l&&l.d(n)}}}function an(t){let e,l="Do you really want to delete the following localStorage keys?",n,r,s=Ce(t[0]),a=[];for(let c=0;c<s.length;c+=1)a[c]=Ht(Bt(t,s,c));return{c(){e=_("p"),e.textContent=l,n=I();for(let c=0;c<a.length;c+=1)a[c].c();r=st(),this.h()},l(c){e=p(c,"P",{class:!0,"data-svelte-h":!0}),oe(e)!=="svelte-12r0p0q"&&(e.textContent=l),n=P(c);for(let u=0;u<a.length;u+=1)a[u].l(c);r=st(),this.h()},h(){f(e,"class","diagTitle svelte-12dj9tj")},m(c,u){J(c,e,u),J(c,n,u);for(let i=0;i<a.length;i+=1)a[i]&&a[i].m(c,u);J(c,r,u)},p(c,u){if(u&9){s=Ce(c[0]);let i;for(i=0;i<s.length;i+=1){const m=Bt(c,s,i);a[i]?a[i].p(m,u):(a[i]=Ht(m),a[i].c(),a[i].m(r.parentNode,r))}for(;i<a.length;i+=1)a[i].d(1);a.length=s.length}},d(c){c&&(k(e),k(n),k(r)),Xe(a,c)}}}function Vt(t){let e,l,n,r,s,a,c=t[17]+"",u,i,m,h=t[2][t[17]]+"",N,v,d,b;function T(){t[12].call(n,t[17])}function g(){return t[13](t[17])}return{c(){e=_("tr"),l=_("td"),n=_("input"),r=I(),s=_("td"),a=_("button"),u=K(c),i=I(),m=_("td"),N=K(h),v=I(),this.h()},l(O){e=p(O,"TR",{class:!0});var D=S(e);l=p(D,"TD",{});var C=S(l);n=p(C,"INPUT",{type:!0}),C.forEach(k),r=P(D),s=p(D,"TD",{class:!0});var z=S(s);a=p(z,"BUTTON",{class:!0});var F=S(a);u=q(F,c),F.forEach(k),z.forEach(k),i=P(D),m=p(D,"TD",{});var A=S(m);N=q(A,h),A.forEach(k),v=P(D),D.forEach(k),this.h()},h(){f(n,"type","checkbox"),f(a,"class","svelte-12dj9tj"),f(s,"class","svelte-12dj9tj"),f(e,"class","svelte-12dj9tj")},m(O,D){J(O,e,D),o(e,l),o(l,n),n.checked=t[3][t[17]],o(e,r),o(e,s),o(s,a),o(a,u),o(e,i),o(e,m),o(m,N),o(e,v),d||(b=[G(n,"change",T),G(a,"click",g)],d=!0)},p(O,D){t=O,D&9&&(n.checked=t[3][t[17]]),D&1&&c!==(c=t[17]+"")&&ve(u,c),D&5&&h!==(h=t[2][t[17]]+"")&&ve(N,h)},d(O){O&&k(e),d=!1,Ye(b)}}}function on(t){let e,l,n="Delete",r,s,a,c,u,i,m,h="<td>Delete</td> <td>Key name</td> <td>Last modification</td>",N,v,d,b,T,g,O="delete all",D,C,z,F,A,w,E;function M(y){t[10](y)}let U={okName:"Confirm",okFunc:t[6],$$slots:{default:[an]},$$scope:{ctx:t}};t[4]!==void 0&&(U.modalOpen=t[4]),s=new gt({props:U}),je.push(()=>Ae(s,"modalOpen",M));let Y=Ce(t[0]),B=[];for(let y=0;y<Y.length;y+=1)B[y]=Vt(Ft(t,Y,y));return{c(){e=_("div"),l=_("button"),l.textContent=n,r=I(),De(s.$$.fragment),c=I(),u=_("table"),i=_("thead"),m=_("tr"),m.innerHTML=h,N=I(),v=_("tr"),d=_("td"),b=_("input"),T=I(),g=_("td"),g.textContent=O,D=I(),C=_("td"),z=I(),F=_("tbody");for(let y=0;y<B.length;y+=1)B[y].c();this.h()},l(y){e=p(y,"DIV",{class:!0});var W=S(e);l=p(W,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(l)!=="svelte-1tbm4xl"&&(l.textContent=n),r=P(W),Ee(s.$$.fragment,W),c=P(W),u=p(W,"TABLE",{class:!0});var te=S(u);i=p(te,"THEAD",{class:!0});var ee=S(i);m=p(ee,"TR",{"data-svelte-h":!0}),oe(m)!=="svelte-xt53kn"&&(m.innerHTML=h),N=P(ee),v=p(ee,"TR",{});var Q=S(v);d=p(Q,"TD",{});var pe=S(d);b=p(pe,"INPUT",{type:!0}),pe.forEach(k),T=P(Q),g=p(Q,"TD",{class:!0,"data-svelte-h":!0}),oe(g)!=="svelte-1s4wssd"&&(g.textContent=O),D=P(Q),C=p(Q,"TD",{}),S(C).forEach(k),Q.forEach(k),ee.forEach(k),z=P(te),F=p(te,"TBODY",{class:!0});var ue=S(F);for(let me=0;me<B.length;me+=1)B[me].l(ue);ue.forEach(k),te.forEach(k),W.forEach(k),this.h()},h(){f(l,"class","svelte-12dj9tj"),f(b,"type","checkbox"),f(g,"class","instruction"),f(i,"class","svelte-12dj9tj"),f(F,"class","svelte-12dj9tj"),f(u,"class","svelte-12dj9tj"),f(e,"class","deleteKeys svelte-12dj9tj")},m(y,W){J(y,e,W),o(e,l),o(e,r),Le(s,e,null),o(e,c),o(e,u),o(u,i),o(i,m),o(i,N),o(i,v),o(v,d),o(d,b),b.checked=t[1],o(v,T),o(v,g),o(v,D),o(v,C),o(u,z),o(u,F);for(let te=0;te<B.length;te+=1)B[te]&&B[te].m(F,null);A=!0,w||(E=[G(l,"click",t[9]),G(b,"change",t[11])],w=!0)},p(y,[W]){const te={};if(W&4194313&&(te.$$scope={dirty:W,ctx:y}),!a&&W&16&&(a=!0,te.modalOpen=y[4],Pe(()=>a=!1)),s.$set(te),W&2&&(b.checked=y[1]),W&45){Y=Ce(y[0]);let ee;for(ee=0;ee<Y.length;ee+=1){const Q=Ft(y,Y,ee);B[ee]?B[ee].p(Q,W):(B[ee]=Vt(Q),B[ee].c(),B[ee].m(F,null))}for(;ee<B.length;ee+=1)B[ee].d(1);B.length=Y.length}},i(y){A||(Te(s.$$.fragment,y),A=!0)},o(y){we(s.$$.fragment,y),A=!1},d(y){y&&k(e),Se(s),Xe(B,y),w=!1,Ye(E)}}}function rn(t){let e={};for(const l of t)e[l]=!1;return e}function cn(t,e,l){let{pageName:n}=e,{storeName:r}=e,{localKeys:s}=e;function a(){let C=[];const z=new RegExp(`^${n}_`);return C=Object.keys(window.localStorage).filter(A=>z.test(A)).map(A=>A.replace(z,"")),C}s=a();function c(C){l(7,r=C)}let u={};function i(C){let z={};for(const F of C){let A="";const w=`${n}_${F}`,E=window.localStorage.getItem(w);E!==null&&(A=JSON.parse(E).lastModif),z[F]=A}return z}u=i(s);let m={};m=rn(s);let h=!1;function N(C){for(const z of s)l(3,m[z]=C,m)}function v(){for(const C of s)if(m[C]){const z=`${n}_${C}`;window.localStorage.removeItem(z)}l(0,s=a())}let d=!1;const b=()=>{l(4,d=!0)};function T(C){d=C,l(4,d)}function g(){h=this.checked,l(1,h)}function O(C){m[C]=this.checked,l(3,m)}const D=C=>c(C);return t.$$set=C=>{"pageName"in C&&l(8,n=C.pageName),"storeName"in C&&l(7,r=C.storeName),"localKeys"in C&&l(0,s=C.localKeys)},t.$$.update=()=>{t.$$.dirty&2&&N(h)},[s,h,u,m,d,c,v,r,n,b,T,g,O,D]}class vl extends Me{constructor(e){super(),ye(this,e,cn,on,ze,{pageName:8,storeName:7,localKeys:0})}}function Wt(t){let e,l,n,r;return{c(){e=_("p"),l=K("Warning: name "),n=K(t[0]),r=K(" already used"),this.h()},l(s){e=p(s,"P",{class:!0});var a=S(e);l=q(a,"Warning: name "),n=q(a,t[0]),r=q(a," already used"),a.forEach(k),this.h()},h(){f(e,"class","warnMsg svelte-1rkdwo")},m(s,a){J(s,e,a),o(e,l),o(e,n),o(e,r)},p(s,a){a&1&&ve(n,s[0])},d(s){s&&k(e)}}}function fn(t){let e,l,n,r,s,a,c="Give a name to your parameter-set:",u,i,m,h,N,v;function d(O){t[5](O)}function b(O){t[6](O)}let T={pageName:t[1]};t[0]!==void 0&&(T.storeName=t[0]),t[2]!==void 0&&(T.localKeys=t[2]),e=new vl({props:T}),je.push(()=>Ae(e,"storeName",d)),je.push(()=>Ae(e,"localKeys",b));let g=t[3]&&Wt(t);return{c(){De(e.$$.fragment),r=I(),s=_("div"),a=_("label"),a.textContent=c,u=I(),i=_("input"),m=I(),g&&g.c(),this.h()},l(O){Ee(e.$$.fragment,O),r=P(O),s=p(O,"DIV",{class:!0});var D=S(s);a=p(D,"LABEL",{for:!0,class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-1vdq35w"&&(a.textContent=c),u=P(D),i=p(D,"INPUT",{type:!0,id:!0,minlength:!0,maxlength:!0,size:!0,class:!0}),m=P(D),g&&g.l(D),D.forEach(k),this.h()},h(){f(a,"for","storName"),f(a,"class","svelte-1rkdwo"),f(i,"type","text"),f(i,"id","storName"),i.required=!0,f(i,"minlength","4"),f(i,"maxlength","30"),f(i,"size","32"),f(i,"class","svelte-1rkdwo"),f(s,"class","svelte-1rkdwo")},m(O,D){Le(e,O,D),J(O,r,D),J(O,s,D),o(s,a),o(s,u),o(s,i),ke(i,t[0]),o(s,m),g&&g.m(s,null),h=!0,N||(v=[G(i,"input",t[7]),G(i,"input",t[4])],N=!0)},p(O,[D]){const C={};D&2&&(C.pageName=O[1]),!l&&D&1&&(l=!0,C.storeName=O[0],Pe(()=>l=!1)),!n&&D&4&&(n=!0,C.localKeys=O[2],Pe(()=>n=!1)),e.$set(C),D&1&&i.value!==O[0]&&ke(i,O[0]),O[3]?g?g.p(O,D):(g=Wt(O),g.c(),g.m(s,null)):g&&(g.d(1),g=null)},i(O){h||(Te(e.$$.fragment,O),h=!0)},o(O){we(e.$$.fragment,O),h=!1},d(O){O&&(k(r),k(s)),Se(e,O),g&&g.d(),N=!1,Ye(v)}}}function un(t){const e=/[-:]/g,l=/\..*$/;return`${t}_${new Date().toISOString().replace(e,"").replace(l,"").replace("T","_")}`}function mn(t,e,l){let{pageName:n}=e,{storeName:r}=e,s=[];r=un(n);let a=!1;function c(N){l(3,a=s.includes(N))}function u(N){const v=N.target.value;c(v)}function i(N){r=N,l(0,r)}function m(N){s=N,l(2,s)}function h(){r=this.value,l(0,r)}return t.$$set=N=>{"pageName"in N&&l(1,n=N.pageName),"storeName"in N&&l(0,r=N.storeName)},t.$$.update=()=>{t.$$.dirty&1&&c(r)},[r,n,s,a,u,i,m,h]}class dn extends Me{constructor(e){super(),ye(this,e,mn,fn,ze,{pageName:1,storeName:0})}}function hn(t){let e,l,n,r,s,a,c="Select a parameter-set:",u,i,m;function h(d){t[3](d)}function N(d){t[4](d)}let v={pageName:t[1]};return t[0]!==void 0&&(v.storeName=t[0]),t[2]!==void 0&&(v.localKeys=t[2]),e=new vl({props:v}),je.push(()=>Ae(e,"storeName",h)),je.push(()=>Ae(e,"localKeys",N)),{c(){De(e.$$.fragment),r=I(),s=_("div"),a=_("label"),a.textContent=c,u=I(),i=_("input"),this.h()},l(d){Ee(e.$$.fragment,d),r=P(d),s=p(d,"DIV",{class:!0});var b=S(s);a=p(b,"LABEL",{for:!0,class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-rajgc0"&&(a.textContent=c),u=P(b),i=p(b,"INPUT",{type:!0,id:!0,minlength:!0,maxlength:!0,size:!0,class:!0}),b.forEach(k),this.h()},h(){f(a,"for","storName"),f(a,"class","svelte-1ozd0ey"),f(i,"type","text"),f(i,"id","storName"),i.value=t[0],i.readOnly=!0,f(i,"minlength","4"),f(i,"maxlength","30"),f(i,"size","32"),f(i,"class","svelte-1ozd0ey"),f(s,"class","svelte-1ozd0ey")},m(d,b){Le(e,d,b),J(d,r,b),J(d,s,b),o(s,a),o(s,u),o(s,i),m=!0},p(d,[b]){const T={};b&2&&(T.pageName=d[1]),!l&&b&1&&(l=!0,T.storeName=d[0],Pe(()=>l=!1)),!n&&b&4&&(n=!0,T.localKeys=d[2],Pe(()=>n=!1)),e.$set(T),(!m||b&1&&i.value!==d[0])&&(i.value=d[0])},i(d){m||(Te(e.$$.fragment,d),m=!0)},o(d){we(e.$$.fragment,d),m=!1},d(d){d&&(k(r),k(s)),Se(e,d)}}}function _n(t,e,l){let{pageName:n}=e,{storeName:r}=e,s=[];function a(i){let m=r;return!i.includes(m)&&(i.length>0?m=i[0]:m=""),m}function c(i){r=i,l(0,r),l(2,s)}function u(i){s=i,l(2,s)}return t.$$set=i=>{"pageName"in i&&l(1,n=i.pageName),"storeName"in i&&l(0,r=i.storeName)},t.$$.update=()=>{t.$$.dirty&4&&l(0,r=a(s))},[r,n,s,c,u]}class pn extends Me{constructor(e){super(),ye(this,e,_n,hn,ze,{pageName:1,storeName:0})}}const Re=ul(Ml());function gn(t){let e;return{c(){e=_("canvas"),this.h()},l(l){e=p(l,"CANVAS",{class:!0,width:!0,height:!0}),S(e).forEach(k),this.h()},h(){f(e,"class","mini svelte-z8e4tz"),f(e,"width",Xt),f(e,"height",Xt)},m(l,n){J(l,e,n),t[9](e)},p:Ue,i:Ue,o:Ue,d(l){l&&k(e),t[9](null)}}}const Xt=200;function vn(t,e,l){let n,r;at(t,Re,T=>l(7,n=T)),at(t,Ke,T=>l(8,r=T));let{pageName:s}=e,{fgeom:a}=e,{selFace:c}=e,{zAdjust:u}=e,{simTime:i=0}=e,m,h;function N(T,g){const O=yl(g);O.ruler=!1;const D=m.getContext("2d");D.clearRect(0,0,D.canvas.width,D.canvas.height);try{u.init===0?h=T.getAdjustFull(D.canvas.width,D.canvas.height):h=u,T.draw(D,h,O)}catch(C){console.log(C)}}let v=0;function d(T,g,O,D){const C=a(T,g).fig;if(Object.keys(C).includes(O)){const z=C[O];N(z,D)}else{const z=dl(C);N(z,D)}}Et(()=>{d(i,r[s],c,n),l(6,v=1)});function b(T){je[T?"unshift":"push"](()=>{m=T,l(0,m)})}return t.$$set=T=>{"pageName"in T&&l(1,s=T.pageName),"fgeom"in T&&l(2,a=T.fgeom),"selFace"in T&&l(3,c=T.selFace),"zAdjust"in T&&l(4,u=T.zAdjust),"simTime"in T&&l(5,i=T.simTime)},t.$$.update=()=>{t.$$.dirty&490&&v===1&&d(i,r[s],c,n)},[m,s,a,c,u,i,v,n,r,b]}class Yt extends Me{constructor(e){super(),ye(this,e,vn,gn,ze,{pageName:1,fgeom:2,selFace:3,zAdjust:4,simTime:5})}}function bn(t,e){const l=document.createElement("a");l.setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(e)),l.setAttribute("download",t),l.click(),l.remove()}function bl(t,e,l){const n=/[-:]/g,r=/\..*$/,s=new Date().toISOString().replace(n,"").replace(r,"").replace("T","_"),a=`px_${t}_${s}.json`,c=hl(s,t,e,l);bn(a,c)}function kn(t,e,l){const n=new URL(t),r=2e3;let s=n.toString().length;for(const a of Object.keys(e)){const c=e[a].toString(),u=2+a.length+c.length;n.searchParams.append(encodeURIComponent(a),encodeURIComponent(c)),s+=u}return s>=r&&console.log(`warn547: generateUrl: strLength ${s} larger than strLengthLimit ${r}`),n.toString()}function Kt(t,e,l){const n=t.slice();return n[58]=e[l],n[59]=e,n[60]=l,n}function qt(t,e,l){const n=t.slice();return n[61]=e[l],n[62]=e,n[63]=l,n}function Gt(t,e,l){const n=t.slice();return n[64]=e[l],n[66]=l,n}function Nn(t,e,l){const n=t.slice();return n[64]=e[l],n[66]=l,n}function Tn(t){let e;return{c(){e=K("Load the default parameters ?")},l(l){e=q(l,"Load the default parameters ?")},m(l,n){J(l,e,n)},d(l){l&&k(e)}}}function wn(t){let e,l,n;function r(a){t[34](a)}let s={pageName:t[0].partName};return t[13]!==void 0&&(s.storeName=t[13]),e=new pn({props:s}),je.push(()=>Ae(e,"storeName",r)),{c(){De(e.$$.fragment)},l(a){Ee(e.$$.fragment,a)},m(a,c){Le(e,a,c),n=!0},p(a,c){const u={};c[0]&1&&(u.pageName=a[0].partName),!l&&c[0]&8192&&(l=!0,u.storeName=a[13],Pe(()=>l=!1)),e.$set(u)},i(a){n||(Te(e.$$.fragment,a),n=!0)},o(a){we(e.$$.fragment,a),n=!1},d(a){Se(e,a)}}}function On(t){let e;return{c(){e=K("unknown")},l(l){e=q(l,"unknown")},m(l,n){J(l,e,n)},p:Ue,d(l){l&&k(e)}}}function Cn(t){let e,l,n,r=Ce(t[61].dropdown),s=[];for(let c=0;c<r.length;c+=1)s[c]=Zt(Gt(t,r,c));function a(){t[41].call(e,t[61])}return{c(){e=_("select");for(let c=0;c<s.length;c+=1)s[c].c();this.h()},l(c){e=p(c,"SELECT",{});var u=S(e);for(let i=0;i<s.length;i+=1)s[i].l(u);u.forEach(k),this.h()},h(){t[19][t[0].partName][t[61].name]===void 0&&bt(a)},m(c,u){J(c,e,u);for(let i=0;i<s.length;i+=1)s[i]&&s[i].m(e,null);ot(e,t[19][t[0].partName][t[61].name],!0),l||(n=G(e,"change",a),l=!0)},p(c,u){if(t=c,u[0]&32){r=Ce(t[61].dropdown);let i;for(i=0;i<r.length;i+=1){const m=Gt(t,r,i);s[i]?s[i].p(m,u):(s[i]=Zt(m),s[i].c(),s[i].m(e,null))}for(;i<s.length;i+=1)s[i].d(1);s.length=r.length}u[0]&524321&&ot(e,t[19][t[0].partName][t[61].name])},d(c){c&&k(e),Xe(s,c),l=!1,n()}}}function Dn(t){let e,l,n,r=Ce(["Off","On"]),s=[];for(let c=0;c<2;c+=1)s[c]=Ln(Nn(t,r,c));function a(){t[40].call(e,t[61])}return{c(){e=_("select");for(let c=0;c<2;c+=1)s[c].c();this.h()},l(c){e=p(c,"SELECT",{});var u=S(e);for(let i=0;i<2;i+=1)s[i].l(u);u.forEach(k),this.h()},h(){t[19][t[0].partName][t[61].name]===void 0&&bt(a)},m(c,u){J(c,e,u);for(let i=0;i<2;i+=1)s[i]&&s[i].m(e,null);ot(e,t[19][t[0].partName][t[61].name],!0),l||(n=G(e,"change",a),l=!0)},p(c,u){t=c,u[0]&524321&&ot(e,t[19][t[0].partName][t[61].name])},d(c){c&&k(e),Xe(s,c),l=!1,n()}}}function En(t){let e,l,n,r,s,a,c,u,i,m,h;function N(){t[38].call(e,t[61])}function v(){t[39].call(a,t[61])}return{c(){e=_("input"),s=I(),a=_("input"),this.h()},l(d){e=p(d,"INPUT",{type:!0,min:!0,max:!0,step:!0,class:!0}),s=P(d),a=p(d,"INPUT",{type:!0,min:!0,max:!0,step:!0,class:!0}),this.h()},h(){f(e,"type","number"),f(e,"min",l=t[61].min),f(e,"max",n=t[61].max),f(e,"step",r=t[61].step),f(e,"class","input-number svelte-1g5tt44"),f(a,"type","range"),f(a,"min",c=t[61].min),f(a,"max",u=t[61].max),f(a,"step",i=t[61].step),f(a,"class","svelte-1g5tt44")},m(d,b){J(d,e,b),ke(e,t[19][t[0].partName][t[61].name]),J(d,s,b),J(d,a,b),ke(a,t[19][t[0].partName][t[61].name]),m||(h=[G(e,"input",N),G(e,"change",t[21]),G(a,"change",v),G(a,"input",v),G(a,"change",t[21])],m=!0)},p(d,b){t=d,b[0]&32&&l!==(l=t[61].min)&&f(e,"min",l),b[0]&32&&n!==(n=t[61].max)&&f(e,"max",n),b[0]&32&&r!==(r=t[61].step)&&f(e,"step",r),b[0]&524321&&_t(e.value)!==t[19][t[0].partName][t[61].name]&&ke(e,t[19][t[0].partName][t[61].name]),b[0]&32&&c!==(c=t[61].min)&&f(a,"min",c),b[0]&32&&u!==(u=t[61].max)&&f(a,"max",u),b[0]&32&&i!==(i=t[61].step)&&f(a,"step",i),b[0]&524321&&ke(a,t[19][t[0].partName][t[61].name])},d(d){d&&(k(e),k(s),k(a)),m=!1,Ye(h)}}}function Zt(t){let e,l=t[64]+"",n;return{c(){e=_("option"),n=K(l),this.h()},l(r){e=p(r,"OPTION",{});var s=S(e);n=q(s,l),s.forEach(k),this.h()},h(){e.__value=t[66],ke(e,e.__value)},m(r,s){J(r,e,s),o(e,n)},p(r,s){s[0]&32&&l!==(l=r[64]+"")&&ve(n,l)},d(r){r&&k(e)}}}function Ln(t){let e,l;return{c(){e=_("option"),l=K(t[64]),this.h()},l(n){e=p(n,"OPTION",{});var r=S(e);l=q(r,t[64]),r.forEach(k),this.h()},h(){e.__value=t[66],ke(e,e.__value)},m(n,r){J(n,e,r),o(e,l)},p:Ue,d(n){n&&k(e)}}}function Jt(t){let e,l,n=t[60]+1+"",r,s,a=t[63]+1+"",c,u,i,m,h=t[61].name+"",N,v,d,b,T,g=t[61].unit+"",O,D,C,z=t[61].init+"",F,A,w,E=t[61].min+"",M,U,Y,B=t[61].max+"",y,W,te,ee=t[61].step+"",Q,pe,ue;function me(){return t[37](t[61])}function be(se,Z){return se[61].pType===wt.eNumber?En:se[61].pType===wt.eCheckbox?Dn:se[61].pType===wt.eDropdown?Cn:On}let j=be(t),H=j(t);return{c(){e=_("tr"),l=_("td"),r=K(n),s=K("."),c=K(a),u=I(),i=_("td"),m=_("button"),N=K(h),v=I(),d=_("td"),H.c(),b=I(),T=_("td"),O=K(g),D=I(),C=_("td"),F=K(z),A=I(),w=_("td"),M=K(E),U=I(),Y=_("td"),y=K(B),W=I(),te=_("td"),Q=K(ee),this.h()},l(se){e=p(se,"TR",{class:!0});var Z=S(e);l=p(Z,"TD",{class:!0});var re=S(l);r=q(re,n),s=q(re,"."),c=q(re,a),re.forEach(k),u=P(Z),i=p(Z,"TD",{class:!0});var $=S(i);m=p($,"BUTTON",{class:!0});var he=S(m);N=q(he,h),he.forEach(k),$.forEach(k),v=P(Z),d=p(Z,"TD",{class:!0});var ce=S(d);H.l(ce),ce.forEach(k),b=P(Z),T=p(Z,"TD",{class:!0});var fe=S(T);O=q(fe,g),fe.forEach(k),D=P(Z),C=p(Z,"TD",{class:!0});var x=S(C);F=q(x,z),x.forEach(k),A=P(Z),w=p(Z,"TD",{class:!0});var L=S(w);M=q(L,E),L.forEach(k),U=P(Z),Y=p(Z,"TD",{class:!0});var V=S(Y);y=q(V,B),V.forEach(k),W=P(Z),te=p(Z,"TD",{class:!0});var le=S(te);Q=q(le,ee),le.forEach(k),Z.forEach(k),this.h()},h(){f(l,"class","svelte-1g5tt44"),f(m,"class","svelte-1g5tt44"),f(i,"class","svelte-1g5tt44"),f(d,"class","svelte-1g5tt44"),f(T,"class","svelte-1g5tt44"),f(C,"class","svelte-1g5tt44"),f(w,"class","svelte-1g5tt44"),f(Y,"class","svelte-1g5tt44"),f(te,"class","svelte-1g5tt44"),f(e,"class","svelte-1g5tt44"),Be(e,"changed",t[19][t[0].partName][t[61].name]!==t[61].init)},m(se,Z){J(se,e,Z),o(e,l),o(l,r),o(l,s),o(l,c),o(e,u),o(e,i),o(i,m),o(m,N),o(e,v),o(e,d),H.m(d,null),o(e,b),o(e,T),o(T,O),o(e,D),o(e,C),o(C,F),o(e,A),o(e,w),o(w,M),o(e,U),o(e,Y),o(Y,y),o(e,W),o(e,te),o(te,Q),pe||(ue=G(m,"click",me),pe=!0)},p(se,Z){t=se,Z[0]&32&&h!==(h=t[61].name+"")&&ve(N,h),j===(j=be(t))&&H?H.p(t,Z):(H.d(1),H=j(t),H&&(H.c(),H.m(d,null))),Z[0]&32&&g!==(g=t[61].unit+"")&&ve(O,g),Z[0]&32&&z!==(z=t[61].init+"")&&ve(F,z),Z[0]&32&&E!==(E=t[61].min+"")&&ve(M,E),Z[0]&32&&B!==(B=t[61].max+"")&&ve(y,B),Z[0]&32&&ee!==(ee=t[61].step+"")&&ve(Q,ee),Z[0]&524321&&Be(e,"changed",t[19][t[0].partName][t[61].name]!==t[61].init)},d(se){se&&k(e),H.d(),pe=!1,ue()}}}function Qt(t){let e,l,n=t[60]+1+"",r,s,a,c=t[58].sectionName+"",u,i,m,h,N,v,d,b="",T,g,O,D,C;function z(){t[36].call(N,t[58])}let F=Ce(t[58].params),A=[];for(let w=0;w<F.length;w+=1)A[w]=Jt(qt(t,F,w));return{c(){e=_("tr"),l=_("td"),r=K(n),s=I(),a=_("td"),u=K(c),i=I(),m=_("td"),h=_("label"),N=_("input"),v=I(),d=_("span"),d.innerHTML=b,T=I(),g=_("tbody");for(let w=0;w<A.length;w+=1)A[w].c();O=I(),this.h()},l(w){e=p(w,"TR",{class:!0});var E=S(e);l=p(E,"TD",{class:!0});var M=S(l);r=q(M,n),M.forEach(k),s=P(E),a=p(E,"TD",{colspan:!0,class:!0});var U=S(a);u=q(U,c),U.forEach(k),i=P(E),m=p(E,"TD",{colspan:!0,class:!0});var Y=S(m);h=p(Y,"LABEL",{class:!0});var B=S(h);N=p(B,"INPUT",{type:!0,class:!0}),v=P(B),d=p(B,"SPAN",{class:!0,"data-svelte-h":!0}),oe(d)!=="svelte-1qufua2"&&(d.innerHTML=b),B.forEach(k),Y.forEach(k),E.forEach(k),T=P(w),g=p(w,"TBODY",{class:!0});var y=S(g);for(let W=0;W<A.length;W+=1)A[W].l(y);O=P(y),y.forEach(k),this.h()},h(){f(l,"class","svelte-1g5tt44"),f(a,"colspan","4"),f(a,"class","svelte-1g5tt44"),f(N,"type","checkbox"),f(N,"class","svelte-1g5tt44"),f(d,"class","svelte-1g5tt44"),f(h,"class","svelte-1g5tt44"),f(m,"colspan","3"),f(m,"class","svelte-1g5tt44"),f(e,"class","separator svelte-1g5tt44"),f(g,"class","svelte-1g5tt44"),Be(g,"collaps",t[18][t[58].sectionID])},m(w,E){J(w,e,E),o(e,l),o(l,r),o(e,s),o(e,a),o(a,u),o(e,i),o(e,m),o(m,h),o(h,N),N.checked=t[18][t[58].sectionID],o(h,v),o(h,d),J(w,T,E),J(w,g,E);for(let M=0;M<A.length;M+=1)A[M]&&A[M].m(g,null);o(g,O),D||(C=G(N,"change",z),D=!0)},p(w,E){if(t=w,E[0]&32&&c!==(c=t[58].sectionName+"")&&ve(u,c),E[0]&262176&&(N.checked=t[18][t[58].sectionID]),E[0]&271056929){F=Ce(t[58].params);let M;for(M=0;M<F.length;M+=1){const U=qt(t,F,M);A[M]?A[M].p(U,E):(A[M]=Jt(U),A[M].c(),A[M].m(g,O))}for(;M<A.length;M+=1)A[M].d(1);A.length=F.length}E[0]&262176&&Be(g,"collaps",t[18][t[58].sectionID])},d(w){w&&(k(e),k(T),k(g)),Xe(A,w),D=!1,C()}}}function Sn(t){let e,l="Copy this URL and send it to your friends!",n,r,s;return{c(){e=_("p"),e.textContent=l,n=I(),r=_("p"),s=K(t[15]),this.h()},l(a){e=p(a,"P",{"data-svelte-h":!0}),oe(e)!=="svelte-1kscrpk"&&(e.textContent=l),n=P(a),r=p(a,"P",{class:!0});var c=S(r);s=q(c,t[15]),c.forEach(k),this.h()},h(){f(r,"class","cUrl svelte-1g5tt44")},m(a,c){J(a,e,c),J(a,n,c),J(a,r,c),o(r,s)},p(a,c){c[0]&32768&&ve(s,a[15])},d(a){a&&(k(e),k(n),k(r))}}}function jn(t){let e,l,n;function r(a){t[45](a)}let s={pageName:t[0].partName};return t[14]!==void 0&&(s.storeName=t[14]),e=new dn({props:s}),je.push(()=>Ae(e,"storeName",r)),{c(){De(e.$$.fragment)},l(a){Ee(e.$$.fragment,a)},m(a,c){Le(e,a,c),n=!0},p(a,c){const u={};c[0]&1&&(u.pageName=a[0].partName),!l&&c[0]&16384&&(l=!0,u.storeName=a[14],Pe(()=>l=!1)),e.$set(u)},i(a){n||(Te(e.$$.fragment,a),n=!0)},o(a){we(e.$$.fragment,a),n=!1},d(a){Se(e,a)}}}function In(t){let e,l,n="Parameters",r,s,a,c="Load Params from File",u,i,m,h,N="Set Params Default",v,d,b="Load Params from localStorage",T,g,O,D,C,z,F,A,w,E,M,U='<tr class="svelte-1g5tt44"><td class="svelte-1g5tt44">#</td> <td class="svelte-1g5tt44">Parameter name</td> <td class="svelte-1g5tt44">Value</td> <td class="svelte-1g5tt44">Unit</td> <td class="svelte-1g5tt44">Default</td> <td class="svelte-1g5tt44">Min</td> <td class="svelte-1g5tt44">Max</td> <td class="svelte-1g5tt44">Step</td></tr>',Y,B,y,W,te="Comment:",ee,Q,pe,ue,me="Save Parameters to File",be,j,H="Save Parameters as URL",se,Z,re="Save Parameters to localStorage",$,he,ce,fe,x,L,V,le,_e,ge,ie,Oe,Je,Qe,xe,qe,pt,R,ae,Ne,Fe,He;function $e(X){t[33](X)}let rt={okName:"Overwrite Parameters",okFunc:t[24],$$slots:{default:[Tn]},$$scope:{ctx:t}};t[9]!==void 0&&(rt.modalOpen=t[9]),g=new gt({props:rt}),je.push(()=>Ae(g,"modalOpen",$e));function kt(X){t[35](X)}let it={okName:"Load Parameters",okFunc:t[25],$$slots:{default:[wn]},$$scope:{ctx:t}};t[10]!==void 0&&(it.modalOpen=t[10]),C=new gt({props:it}),je.push(()=>Ae(C,"modalOpen",kt));let et=Ce(t[5]),Ie=[];for(let X=0;X<et.length;X+=1)Ie[X]=Qt(Kt(t,et,X));function Lt(X){t[44](X)}let Ve={okName:"Done",okFunc:Pn,sizeLarge:!0,$$slots:{default:[Sn]},$$scope:{ctx:t}};t[11]!==void 0&&(Ve.modalOpen=t[11]),he=new gt({props:Ve}),je.push(()=>Ae(he,"modalOpen",Lt));function Nl(X){t[46](X)}let St={okName:"Save into localStorage",okFunc:t[26],$$slots:{default:[jn]},$$scope:{ctx:t}};t[12]!==void 0&&(St.modalOpen=t[12]),x=new gt({props:St}),je.push(()=>Ae(x,"modalOpen",Nl));function Tl(X){t[47](X)}let jt={svgPath:t[16]};return t[17]!==void 0&&(jt.modalOpen=t[17]),le=new gl({props:jt}),je.push(()=>Ae(le,"modalOpen",Tl)),qe=new Yt({props:{pageName:t[0].partName,fgeom:t[1],selFace:t[2],zAdjust:t[20],simTime:t[4]}}),ae=new Yt({props:{pageName:t[0].partName,fgeom:t[1],selFace:t[2],zAdjust:t[3],simTime:t[4]}}),{c(){e=_("section"),l=_("h2"),l.textContent=n,r=I(),s=_("main"),a=_("label"),a.textContent=c,u=I(),i=_("input"),m=I(),h=_("button"),h.textContent=N,v=I(),d=_("button"),d.textContent=b,T=I(),De(g.$$.fragment),D=I(),De(C.$$.fragment),F=I(),A=_("textarea"),w=I(),E=_("table"),M=_("thead"),M.innerHTML=U,Y=I();for(let X=0;X<Ie.length;X+=1)Ie[X].c();B=I(),y=_("div"),W=_("label"),W.textContent=te,ee=I(),Q=_("input"),pe=I(),ue=_("button"),ue.textContent=me,be=I(),j=_("button"),j.textContent=H,se=I(),Z=_("button"),Z.textContent=re,$=I(),De(he.$$.fragment),fe=I(),De(x.$$.fragment),V=I(),De(le.$$.fragment),ge=I(),ie=_("button"),Oe=_("img"),Qe=I(),xe=_("div"),De(qe.$$.fragment),pt=I(),R=_("div"),De(ae.$$.fragment),this.h()},l(X){e=p(X,"SECTION",{class:!0});var ne=S(e);l=p(ne,"H2",{class:!0,"data-svelte-h":!0}),oe(l)!=="svelte-1mc497a"&&(l.textContent=n),r=P(ne),s=p(ne,"MAIN",{class:!0});var de=S(s);a=p(de,"LABEL",{for:!0,class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-zt7rok"&&(a.textContent=c),u=P(de),i=p(de,"INPUT",{id:!0,type:!0,accept:!0,class:!0}),m=P(de),h=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(h)!=="svelte-1typ5"&&(h.textContent=N),v=P(de),d=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(d)!=="svelte-187bpo6"&&(d.textContent=b),T=P(de),Ee(g.$$.fragment,de),D=P(de),Ee(C.$$.fragment,de),F=P(de),A=p(de,"TEXTAREA",{rows:!0,cols:!0,wrap:!0,class:!0}),S(A).forEach(k),w=P(de),E=p(de,"TABLE",{class:!0});var tt=S(E);M=p(tt,"THEAD",{class:!0,"data-svelte-h":!0}),oe(M)!=="svelte-1szl7uo"&&(M.innerHTML=U),Y=P(tt);for(let Ge=0;Ge<Ie.length;Ge+=1)Ie[Ge].l(tt);tt.forEach(k),B=P(de),y=p(de,"DIV",{class:!0});var lt=S(y);W=p(lt,"LABEL",{for:!0,"data-svelte-h":!0}),oe(W)!=="svelte-gqskth"&&(W.textContent=te),ee=P(lt),Q=p(lt,"INPUT",{type:!0,id:!0,maxlength:!0,size:!0}),lt.forEach(k),pe=P(de),ue=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(ue)!=="svelte-1ny58g0"&&(ue.textContent=me),be=P(de),j=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(j)!=="svelte-11or0m2"&&(j.textContent=H),se=P(de),Z=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(Z)!=="svelte-5zdtrl"&&(Z.textContent=re),$=P(de),Ee(he.$$.fragment,de),fe=P(de),Ee(x.$$.fragment,de),de.forEach(k),V=P(ne),Ee(le.$$.fragment,ne),ge=P(ne),ie=p(ne,"BUTTON",{class:!0});var ut=S(ie);Oe=p(ut,"IMG",{src:!0,alt:!0,class:!0}),ut.forEach(k),Qe=P(ne),xe=p(ne,"DIV",{class:!0});var mt=S(xe);Ee(qe.$$.fragment,mt),mt.forEach(k),pt=P(ne),R=p(ne,"DIV",{class:!0});var nt=S(R);Ee(ae.$$.fragment,nt),nt.forEach(k),ne.forEach(k),this.h()},h(){f(l,"class","svelte-1g5tt44"),f(a,"for","loadFParams"),f(a,"class","fileUpload svelte-1g5tt44"),f(i,"id","loadFParams"),f(i,"type","file"),f(i,"accept","text/plain, application/json"),f(i,"class","svelte-1g5tt44"),f(h,"class","svelte-1g5tt44"),f(d,"class","svelte-1g5tt44"),f(A,"rows","3"),f(A,"cols","80"),A.readOnly=!0,f(A,"wrap","off"),A.value=t[7],f(A,"class","svelte-1g5tt44"),Be(A,"colorWarn",t[8]),f(M,"class","svelte-1g5tt44"),f(E,"class","svelte-1g5tt44"),f(W,"for","inComment"),f(Q,"type","text"),f(Q,"id","inComment"),f(Q,"maxlength","150"),f(Q,"size","70"),f(y,"class","comment svelte-1g5tt44"),f(ue,"class","svelte-1g5tt44"),f(j,"class","svelte-1g5tt44"),f(Z,"class","svelte-1g5tt44"),f(s,"class","svelte-1g5tt44"),ht(Oe.src,Je=t[16])||f(Oe,"src",Je),f(Oe,"alt",t[16]),f(Oe,"class","svelte-1g5tt44"),f(ie,"class","side-img svelte-1g5tt44"),f(xe,"class","mini-canvas svelte-1g5tt44"),f(R,"class","mini-canvas svelte-1g5tt44"),f(e,"class","svelte-1g5tt44")},m(X,ne){J(X,e,ne),o(e,l),o(e,r),o(e,s),o(s,a),o(s,u),o(s,i),o(s,m),o(s,h),o(s,v),o(s,d),o(s,T),Le(g,s,null),o(s,D),Le(C,s,null),o(s,F),o(s,A),o(s,w),o(s,E),o(E,M),o(E,Y);for(let de=0;de<Ie.length;de+=1)Ie[de]&&Ie[de].m(E,null);o(s,B),o(s,y),o(y,W),o(y,ee),o(y,Q),ke(Q,t[6]),o(s,pe),o(s,ue),o(s,be),o(s,j),o(s,se),o(s,Z),o(s,$),Le(he,s,null),o(s,fe),Le(x,s,null),o(e,V),Le(le,e,null),o(e,ge),o(e,ie),o(ie,Oe),o(e,Qe),o(e,xe),Le(qe,xe,null),o(e,pt),o(e,R),Le(ae,R,null),Ne=!0,Fe||(He=[G(i,"change",t[22]),G(h,"click",t[31]),G(d,"click",t[32]),G(Q,"input",t[42]),G(ue,"click",t[23]),G(j,"click",t[27]),G(Z,"click",t[43]),G(ie,"click",t[29])],Fe=!0)},p(X,ne){const de={};ne[2]&64&&(de.$$scope={dirty:ne,ctx:X}),!O&&ne[0]&512&&(O=!0,de.modalOpen=X[9],Pe(()=>O=!1)),g.$set(de);const tt={};if(ne[0]&8193|ne[2]&64&&(tt.$$scope={dirty:ne,ctx:X}),!z&&ne[0]&1024&&(z=!0,tt.modalOpen=X[10],Pe(()=>z=!1)),C.$set(tt),(!Ne||ne[0]&128)&&(A.value=X[7]),(!Ne||ne[0]&256)&&Be(A,"colorWarn",X[8]),ne[0]&271319073){et=Ce(X[5]);let We;for(We=0;We<et.length;We+=1){const It=Kt(X,et,We);Ie[We]?Ie[We].p(It,ne):(Ie[We]=Qt(It),Ie[We].c(),Ie[We].m(E,null))}for(;We<Ie.length;We+=1)Ie[We].d(1);Ie.length=et.length}ne[0]&64&&Q.value!==X[6]&&ke(Q,X[6]);const lt={};ne[0]&32768|ne[2]&64&&(lt.$$scope={dirty:ne,ctx:X}),!ce&&ne[0]&2048&&(ce=!0,lt.modalOpen=X[11],Pe(()=>ce=!1)),he.$set(lt);const ut={};ne[0]&16385|ne[2]&64&&(ut.$$scope={dirty:ne,ctx:X}),!L&&ne[0]&4096&&(L=!0,ut.modalOpen=X[12],Pe(()=>L=!1)),x.$set(ut);const mt={};ne[0]&65536&&(mt.svgPath=X[16]),!_e&&ne[0]&131072&&(_e=!0,mt.modalOpen=X[17],Pe(()=>_e=!1)),le.$set(mt),(!Ne||ne[0]&65536&&!ht(Oe.src,Je=X[16]))&&f(Oe,"src",Je),(!Ne||ne[0]&65536)&&f(Oe,"alt",X[16]);const nt={};ne[0]&1&&(nt.pageName=X[0].partName),ne[0]&2&&(nt.fgeom=X[1]),ne[0]&4&&(nt.selFace=X[2]),ne[0]&16&&(nt.simTime=X[4]),qe.$set(nt);const Ge={};ne[0]&1&&(Ge.pageName=X[0].partName),ne[0]&2&&(Ge.fgeom=X[1]),ne[0]&4&&(Ge.selFace=X[2]),ne[0]&8&&(Ge.zAdjust=X[3]),ne[0]&16&&(Ge.simTime=X[4]),ae.$set(Ge)},i(X){Ne||(Te(g.$$.fragment,X),Te(C.$$.fragment,X),Te(he.$$.fragment,X),Te(x.$$.fragment,X),Te(le.$$.fragment,X),Te(qe.$$.fragment,X),Te(ae.$$.fragment,X),Ne=!0)},o(X){we(g.$$.fragment,X),we(C.$$.fragment,X),we(he.$$.fragment,X),we(x.$$.fragment,X),we(le.$$.fragment,X),we(qe.$$.fragment,X),we(ae.$$.fragment,X),Ne=!1},d(X){X&&k(e),Se(g),Se(C),Xe(Ie,X),Se(he),Se(x),Se(le),Se(qe),Se(ae),Fe=!1,Ye(He)}}}function Pn(){}function An(t){const e={};for(const l of t)e[l.sectionID]=l.sectionVisible;return e}function Un(t,e,l){let n,r;at(t,Ke,R=>l(19,n=R)),at(t,ql,R=>l(48,r=R));const s=ml();let{pDef:a}=e,{fgeom:c}=e,{selFace:u}=e,{zAdjust:i}=e,{simTime:m=0}=e;const h=_l();let N="";function v(){s("paramChg",{foo:"bla"})}function d(R,ae){let Ne="",Fe=!1;R!==a.partName&&(Ne+=`warn361: read partName: '${R}' expected partName: '${a.partName}'
|
|
1
|
+
import{a as Pt,b as wl}from"../chunks/makeList.D9WwT8E8.js";import{H as Ol,w as ul,g as Cl}from"../chunks/entry.BFaAd9jL.js";import{Q as Dl,s as ze,p as st,i as J,n as Ue,f as k,e as _,c as p,b as S,R as ht,m as f,h as o,S as G,v as je,a as I,g as P,T as Pe,o as Xe,y as El,t as K,l as oe,d as q,U as Be,z as Ll,A as Sl,B as jl,j as ve,C as Ye,V as ke,k as at,r as Et,W as ml,X as _t,Y as Ot,Z as Il,H as bt,_ as ot,$ as Pl,a0 as Al}from"../chunks/scheduler.2BOoCPD3.js";import{S as Me,i as ye,f as Ae,b as De,d as Ee,m as Le,a as Te,t as we,e as Se,g as Ul,c as zl}from"../chunks/index.BugmtA6_.js";import{e as Ce,D as Ml,F as dl,G as yl,H as hl,I as _l,P as wt,J as Fl,K as Nt,L as ct,M as Bl,N as Rl,O as Ct,Q as Hl,R as At,f as dt,r as Dt,T as Ze,U as Vl,V as Wl,W as Xl,X as Yl,Y as Kl}from"../chunks/index.FRem4NB_.js";import{b as vt}from"../chunks/paths.CmHCI0tQ.js";import{p as ql}from"../chunks/stores.CNgkQH-j.js";function Gl(t,e){throw new Ol(t,e)}new TextEncoder;function Zl({params:t}){const e=t.design;if(Object.keys(Pt).includes(e))return{pageDef:Pt[e],allLink:wl};Gl(404,"Design undefined!")}const vs=Object.freeze(Object.defineProperty({__proto__:null,load:Zl},Symbol.toStringTag,{value:"Module"})),Ke=ul({});function pl(t,e,l){const n=Dl(Ke);if(Object.keys(n).includes(t)){const s=n[t],a=Object.keys(s);for(const c of Object.keys(e))a.includes(c)?l&&(s[c]=e[c]):s[c]=e[c];n[t]=s}else n[t]=e;Ke.set(n)}function Jl(t){const e=t.pDef.partName,l={};for(const n of t.pDef.params)l[n.name]=n.init;pl(e,l,!1)}function Ut(t){let e,l,n,r,s,a,c;return{c(){e=_("aside"),l=_("div"),n=_("button"),r=_("img"),this.h()},l(u){e=p(u,"ASIDE",{class:!0});var i=S(e);l=p(i,"DIV",{class:!0});var m=S(l);n=p(m,"BUTTON",{class:!0});var h=S(n);r=p(h,"IMG",{src:!0,alt:!0}),h.forEach(k),m.forEach(k),i.forEach(k),this.h()},h(){ht(r.src,s=t[1])||f(r,"src",s),f(r,"alt",t[1]),f(n,"class","svelte-sjxf1e"),f(l,"class","dialog svelte-sjxf1e"),f(e,"class","backdrop svelte-sjxf1e")},m(u,i){J(u,e,i),o(e,l),o(l,n),o(n,r),a||(c=G(n,"click",t[2]),a=!0)},p(u,i){i&2&&!ht(r.src,s=u[1])&&f(r,"src",s),i&2&&f(r,"alt",u[1])},d(u){u&&k(e),a=!1,c()}}}function Ql(t){let e,l=t[0]&&Ut(t);return{c(){l&&l.c(),e=st()},l(n){l&&l.l(n),e=st()},m(n,r){l&&l.m(n,r),J(n,e,r)},p(n,[r]){n[0]?l?l.p(n,r):(l=Ut(n),l.c(),l.m(e.parentNode,e)):l&&(l.d(1),l=null)},i:Ue,o:Ue,d(n){n&&k(e),l&&l.d(n)}}}function $l(t,e,l){let{svgPath:n}=e,{modalOpen:r}=e;function s(){l(0,r=!1)}return t.$$set=a=>{"svgPath"in a&&l(1,n=a.svgPath),"modalOpen"in a&&l(0,r=a.modalOpen)},[r,n,s]}class gl extends Me{constructor(e){super(),ye(this,e,$l,Ql,ze,{svgPath:1,modalOpen:0})}}function zt(t,e,l){const n=t.slice();return n[8]=e[l],n}function Mt(t){let e,l,n,r,s,a,c;function u(){return t[6](t[8])}return{c(){e=_("button"),l=_("img"),s=I(),this.h()},l(i){e=p(i,"BUTTON",{class:!0});var m=S(e);l=p(m,"IMG",{src:!0,alt:!0,class:!0}),s=P(m),m.forEach(k),this.h()},h(){ht(l.src,n=t[8])||f(l,"src",n),f(l,"alt",r=t[8]),f(l,"class","svelte-fxmnfh"),f(e,"class","svelte-fxmnfh")},m(i,m){J(i,e,m),o(e,l),o(e,s),a||(c=G(e,"click",u),a=!0)},p(i,m){t=i,m&1&&!ht(l.src,n=t[8])&&f(l,"src",n),m&1&&r!==(r=t[8])&&f(l,"alt",r)},d(i){i&&k(e),a=!1,c()}}}function xl(t){let e,l,n,r,s;function a(m){t[5](m)}let c={svgPath:t[2]};t[1]!==void 0&&(c.modalOpen=t[1]),l=new gl({props:c}),je.push(()=>Ae(l,"modalOpen",a));let u=Ce(t[0]),i=[];for(let m=0;m<u.length;m+=1)i[m]=Mt(zt(t,u,m));return{c(){e=_("section"),De(l.$$.fragment),r=I();for(let m=0;m<i.length;m+=1)i[m].c();this.h()},l(m){e=p(m,"SECTION",{class:!0});var h=S(e);Ee(l.$$.fragment,h),r=P(h);for(let N=0;N<i.length;N+=1)i[N].l(h);h.forEach(k),this.h()},h(){f(e,"class","svelte-fxmnfh")},m(m,h){J(m,e,h),Le(l,e,null),o(e,r);for(let N=0;N<i.length;N+=1)i[N]&&i[N].m(e,null);s=!0},p(m,[h]){const N={};if(h&4&&(N.svgPath=m[2]),!n&&h&2&&(n=!0,N.modalOpen=m[1],Pe(()=>n=!1)),l.$set(N),h&9){u=Ce(m[0]);let v;for(v=0;v<u.length;v+=1){const d=zt(m,u,v);i[v]?i[v].p(d,h):(i[v]=Mt(d),i[v].c(),i[v].m(e,null))}for(;v<i.length;v+=1)i[v].d(1);i.length=u.length}},i(m){s||(Te(l.$$.fragment,m),s=!0)},o(m){we(l.$$.fragment,m),s=!1},d(m){m&&k(e),Se(l),Xe(i,m)}}}function en(t){const e=[];for(const l of Object.values(t.paramSvg))e.includes(l)||e.push(l);return e}function tn(t,e,l){let{pDef:n}=e;function r(h){const N=en(n),v=[];for(const d of N)v.push(`${vt}/pgdsvg/${d}`);return v}let s=[],a=!1,c;function u(h){l(2,c=h),l(1,a=!0)}function i(h){a=h,l(1,a)}const m=h=>u(h);return t.$$set=h=>{"pDef"in h&&l(4,n=h.pDef)},t.$$.update=()=>{t.$$.dirty&16&&l(0,s=r(n.partName))},[s,a,c,u,n,i,m]}class ln extends Me{constructor(e){super(),ye(this,e,tn,xl,ze,{pDef:4})}}function yt(t){let e,l,n,r,s,a,c="Cancel",u,i,m,h,N,v;const d=t[7].default,b=El(d,t,t[6],null);return{c(){e=_("aside"),l=_("div"),n=_("article"),b&&b.c(),r=I(),s=_("footer"),a=_("button"),a.textContent=c,u=I(),i=_("button"),m=K(t[1]),this.h()},l(T){e=p(T,"ASIDE",{class:!0});var g=S(e);l=p(g,"DIV",{class:!0});var O=S(l);n=p(O,"ARTICLE",{class:!0});var D=S(n);b&&b.l(D),D.forEach(k),r=P(O),s=p(O,"FOOTER",{class:!0});var C=S(s);a=p(C,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-hcvk9s"&&(a.textContent=c),u=P(C),i=p(C,"BUTTON",{class:!0});var z=S(i);m=q(z,t[1]),z.forEach(k),C.forEach(k),O.forEach(k),g.forEach(k),this.h()},h(){f(n,"class","question svelte-weruk7"),f(a,"class","cancel svelte-weruk7"),f(i,"class","ok svelte-weruk7"),f(s,"class","svelte-weruk7"),f(l,"class","dialog svelte-weruk7"),Be(l,"sizeLarge",t[2]),f(e,"class","backdrop svelte-weruk7")},m(T,g){J(T,e,g),o(e,l),o(l,n),b&&b.m(n,null),o(l,r),o(l,s),o(s,a),o(s,u),o(s,i),o(i,m),h=!0,N||(v=[G(a,"click",t[3]),G(i,"click",t[4])],N=!0)},p(T,g){b&&b.p&&(!h||g&64)&&Ll(b,d,T,T[6],h?jl(d,T[6],g,null):Sl(T[6]),null),(!h||g&2)&&ve(m,T[1]),(!h||g&4)&&Be(l,"sizeLarge",T[2])},i(T){h||(Te(b,T),h=!0)},o(T){we(b,T),h=!1},d(T){T&&k(e),b&&b.d(T),N=!1,Ye(v)}}}function nn(t){let e,l,n=t[0]&&yt(t);return{c(){n&&n.c(),e=st()},l(r){n&&n.l(r),e=st()},m(r,s){n&&n.m(r,s),J(r,e,s),l=!0},p(r,[s]){r[0]?n?(n.p(r,s),s&1&&Te(n,1)):(n=yt(r),n.c(),Te(n,1),n.m(e.parentNode,e)):n&&(Ul(),we(n,1,1,()=>{n=null}),zl())},i(r){l||(Te(n),l=!0)},o(r){we(n),l=!1},d(r){r&&k(e),n&&n.d(r)}}}function sn(t,e,l){let{$$slots:n={},$$scope:r}=e,{okName:s="Ok"}=e,{okFunc:a}=e,{modalOpen:c}=e,{sizeLarge:u=!1}=e;function i(){l(0,c=!1)}function m(){a(),l(0,c=!1)}return t.$$set=h=>{"okName"in h&&l(1,s=h.okName),"okFunc"in h&&l(5,a=h.okFunc),"modalOpen"in h&&l(0,c=h.modalOpen),"sizeLarge"in h&&l(2,u=h.sizeLarge),"$$scope"in h&&l(6,r=h.$$scope)},[c,s,u,i,m,a,r,n]}class gt extends Me{constructor(e){super(),ye(this,e,sn,nn,ze,{okName:1,okFunc:5,modalOpen:0,sizeLarge:2})}}function Ft(t,e,l){const n=t.slice();return n[17]=e[l],n[18]=e,n[19]=l,n}function Bt(t,e,l){const n=t.slice();return n[17]=e[l],n}function Rt(t){let e,l=t[17]+"",n;return{c(){e=_("p"),n=K(l),this.h()},l(r){e=p(r,"P",{class:!0});var s=S(e);n=q(s,l),s.forEach(k),this.h()},h(){f(e,"class","diagItem svelte-12dj9tj")},m(r,s){J(r,e,s),o(e,n)},p(r,s){s&1&&l!==(l=r[17]+"")&&ve(n,l)},d(r){r&&k(e)}}}function Ht(t){let e,l=t[3][t[17]]&&Rt(t);return{c(){l&&l.c(),e=st()},l(n){l&&l.l(n),e=st()},m(n,r){l&&l.m(n,r),J(n,e,r)},p(n,r){n[3][n[17]]?l?l.p(n,r):(l=Rt(n),l.c(),l.m(e.parentNode,e)):l&&(l.d(1),l=null)},d(n){n&&k(e),l&&l.d(n)}}}function an(t){let e,l="Do you really want to delete the following localStorage keys?",n,r,s=Ce(t[0]),a=[];for(let c=0;c<s.length;c+=1)a[c]=Ht(Bt(t,s,c));return{c(){e=_("p"),e.textContent=l,n=I();for(let c=0;c<a.length;c+=1)a[c].c();r=st(),this.h()},l(c){e=p(c,"P",{class:!0,"data-svelte-h":!0}),oe(e)!=="svelte-12r0p0q"&&(e.textContent=l),n=P(c);for(let u=0;u<a.length;u+=1)a[u].l(c);r=st(),this.h()},h(){f(e,"class","diagTitle svelte-12dj9tj")},m(c,u){J(c,e,u),J(c,n,u);for(let i=0;i<a.length;i+=1)a[i]&&a[i].m(c,u);J(c,r,u)},p(c,u){if(u&9){s=Ce(c[0]);let i;for(i=0;i<s.length;i+=1){const m=Bt(c,s,i);a[i]?a[i].p(m,u):(a[i]=Ht(m),a[i].c(),a[i].m(r.parentNode,r))}for(;i<a.length;i+=1)a[i].d(1);a.length=s.length}},d(c){c&&(k(e),k(n),k(r)),Xe(a,c)}}}function Vt(t){let e,l,n,r,s,a,c=t[17]+"",u,i,m,h=t[2][t[17]]+"",N,v,d,b;function T(){t[12].call(n,t[17])}function g(){return t[13](t[17])}return{c(){e=_("tr"),l=_("td"),n=_("input"),r=I(),s=_("td"),a=_("button"),u=K(c),i=I(),m=_("td"),N=K(h),v=I(),this.h()},l(O){e=p(O,"TR",{class:!0});var D=S(e);l=p(D,"TD",{});var C=S(l);n=p(C,"INPUT",{type:!0}),C.forEach(k),r=P(D),s=p(D,"TD",{class:!0});var z=S(s);a=p(z,"BUTTON",{class:!0});var F=S(a);u=q(F,c),F.forEach(k),z.forEach(k),i=P(D),m=p(D,"TD",{});var A=S(m);N=q(A,h),A.forEach(k),v=P(D),D.forEach(k),this.h()},h(){f(n,"type","checkbox"),f(a,"class","svelte-12dj9tj"),f(s,"class","svelte-12dj9tj"),f(e,"class","svelte-12dj9tj")},m(O,D){J(O,e,D),o(e,l),o(l,n),n.checked=t[3][t[17]],o(e,r),o(e,s),o(s,a),o(a,u),o(e,i),o(e,m),o(m,N),o(e,v),d||(b=[G(n,"change",T),G(a,"click",g)],d=!0)},p(O,D){t=O,D&9&&(n.checked=t[3][t[17]]),D&1&&c!==(c=t[17]+"")&&ve(u,c),D&5&&h!==(h=t[2][t[17]]+"")&&ve(N,h)},d(O){O&&k(e),d=!1,Ye(b)}}}function on(t){let e,l,n="Delete",r,s,a,c,u,i,m,h="<td>Delete</td> <td>Key name</td> <td>Last modification</td>",N,v,d,b,T,g,O="delete all",D,C,z,F,A,w,E;function M(y){t[10](y)}let U={okName:"Confirm",okFunc:t[6],$$slots:{default:[an]},$$scope:{ctx:t}};t[4]!==void 0&&(U.modalOpen=t[4]),s=new gt({props:U}),je.push(()=>Ae(s,"modalOpen",M));let Y=Ce(t[0]),B=[];for(let y=0;y<Y.length;y+=1)B[y]=Vt(Ft(t,Y,y));return{c(){e=_("div"),l=_("button"),l.textContent=n,r=I(),De(s.$$.fragment),c=I(),u=_("table"),i=_("thead"),m=_("tr"),m.innerHTML=h,N=I(),v=_("tr"),d=_("td"),b=_("input"),T=I(),g=_("td"),g.textContent=O,D=I(),C=_("td"),z=I(),F=_("tbody");for(let y=0;y<B.length;y+=1)B[y].c();this.h()},l(y){e=p(y,"DIV",{class:!0});var W=S(e);l=p(W,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(l)!=="svelte-1tbm4xl"&&(l.textContent=n),r=P(W),Ee(s.$$.fragment,W),c=P(W),u=p(W,"TABLE",{class:!0});var te=S(u);i=p(te,"THEAD",{class:!0});var ee=S(i);m=p(ee,"TR",{"data-svelte-h":!0}),oe(m)!=="svelte-xt53kn"&&(m.innerHTML=h),N=P(ee),v=p(ee,"TR",{});var Q=S(v);d=p(Q,"TD",{});var pe=S(d);b=p(pe,"INPUT",{type:!0}),pe.forEach(k),T=P(Q),g=p(Q,"TD",{class:!0,"data-svelte-h":!0}),oe(g)!=="svelte-1s4wssd"&&(g.textContent=O),D=P(Q),C=p(Q,"TD",{}),S(C).forEach(k),Q.forEach(k),ee.forEach(k),z=P(te),F=p(te,"TBODY",{class:!0});var ue=S(F);for(let me=0;me<B.length;me+=1)B[me].l(ue);ue.forEach(k),te.forEach(k),W.forEach(k),this.h()},h(){f(l,"class","svelte-12dj9tj"),f(b,"type","checkbox"),f(g,"class","instruction"),f(i,"class","svelte-12dj9tj"),f(F,"class","svelte-12dj9tj"),f(u,"class","svelte-12dj9tj"),f(e,"class","deleteKeys svelte-12dj9tj")},m(y,W){J(y,e,W),o(e,l),o(e,r),Le(s,e,null),o(e,c),o(e,u),o(u,i),o(i,m),o(i,N),o(i,v),o(v,d),o(d,b),b.checked=t[1],o(v,T),o(v,g),o(v,D),o(v,C),o(u,z),o(u,F);for(let te=0;te<B.length;te+=1)B[te]&&B[te].m(F,null);A=!0,w||(E=[G(l,"click",t[9]),G(b,"change",t[11])],w=!0)},p(y,[W]){const te={};if(W&4194313&&(te.$$scope={dirty:W,ctx:y}),!a&&W&16&&(a=!0,te.modalOpen=y[4],Pe(()=>a=!1)),s.$set(te),W&2&&(b.checked=y[1]),W&45){Y=Ce(y[0]);let ee;for(ee=0;ee<Y.length;ee+=1){const Q=Ft(y,Y,ee);B[ee]?B[ee].p(Q,W):(B[ee]=Vt(Q),B[ee].c(),B[ee].m(F,null))}for(;ee<B.length;ee+=1)B[ee].d(1);B.length=Y.length}},i(y){A||(Te(s.$$.fragment,y),A=!0)},o(y){we(s.$$.fragment,y),A=!1},d(y){y&&k(e),Se(s),Xe(B,y),w=!1,Ye(E)}}}function rn(t){let e={};for(const l of t)e[l]=!1;return e}function cn(t,e,l){let{pageName:n}=e,{storeName:r}=e,{localKeys:s}=e;function a(){let C=[];const z=new RegExp(`^${n}_`);return C=Object.keys(window.localStorage).filter(A=>z.test(A)).map(A=>A.replace(z,"")),C}s=a();function c(C){l(7,r=C)}let u={};function i(C){let z={};for(const F of C){let A="";const w=`${n}_${F}`,E=window.localStorage.getItem(w);E!==null&&(A=JSON.parse(E).lastModif),z[F]=A}return z}u=i(s);let m={};m=rn(s);let h=!1;function N(C){for(const z of s)l(3,m[z]=C,m)}function v(){for(const C of s)if(m[C]){const z=`${n}_${C}`;window.localStorage.removeItem(z)}l(0,s=a())}let d=!1;const b=()=>{l(4,d=!0)};function T(C){d=C,l(4,d)}function g(){h=this.checked,l(1,h)}function O(C){m[C]=this.checked,l(3,m)}const D=C=>c(C);return t.$$set=C=>{"pageName"in C&&l(8,n=C.pageName),"storeName"in C&&l(7,r=C.storeName),"localKeys"in C&&l(0,s=C.localKeys)},t.$$.update=()=>{t.$$.dirty&2&&N(h)},[s,h,u,m,d,c,v,r,n,b,T,g,O,D]}class vl extends Me{constructor(e){super(),ye(this,e,cn,on,ze,{pageName:8,storeName:7,localKeys:0})}}function Wt(t){let e,l,n,r;return{c(){e=_("p"),l=K("Warning: name "),n=K(t[0]),r=K(" already used"),this.h()},l(s){e=p(s,"P",{class:!0});var a=S(e);l=q(a,"Warning: name "),n=q(a,t[0]),r=q(a," already used"),a.forEach(k),this.h()},h(){f(e,"class","warnMsg svelte-1rkdwo")},m(s,a){J(s,e,a),o(e,l),o(e,n),o(e,r)},p(s,a){a&1&&ve(n,s[0])},d(s){s&&k(e)}}}function fn(t){let e,l,n,r,s,a,c="Give a name to your parameter-set:",u,i,m,h,N,v;function d(O){t[5](O)}function b(O){t[6](O)}let T={pageName:t[1]};t[0]!==void 0&&(T.storeName=t[0]),t[2]!==void 0&&(T.localKeys=t[2]),e=new vl({props:T}),je.push(()=>Ae(e,"storeName",d)),je.push(()=>Ae(e,"localKeys",b));let g=t[3]&&Wt(t);return{c(){De(e.$$.fragment),r=I(),s=_("div"),a=_("label"),a.textContent=c,u=I(),i=_("input"),m=I(),g&&g.c(),this.h()},l(O){Ee(e.$$.fragment,O),r=P(O),s=p(O,"DIV",{class:!0});var D=S(s);a=p(D,"LABEL",{for:!0,class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-1vdq35w"&&(a.textContent=c),u=P(D),i=p(D,"INPUT",{type:!0,id:!0,minlength:!0,maxlength:!0,size:!0,class:!0}),m=P(D),g&&g.l(D),D.forEach(k),this.h()},h(){f(a,"for","storName"),f(a,"class","svelte-1rkdwo"),f(i,"type","text"),f(i,"id","storName"),i.required=!0,f(i,"minlength","4"),f(i,"maxlength","30"),f(i,"size","32"),f(i,"class","svelte-1rkdwo"),f(s,"class","svelte-1rkdwo")},m(O,D){Le(e,O,D),J(O,r,D),J(O,s,D),o(s,a),o(s,u),o(s,i),ke(i,t[0]),o(s,m),g&&g.m(s,null),h=!0,N||(v=[G(i,"input",t[7]),G(i,"input",t[4])],N=!0)},p(O,[D]){const C={};D&2&&(C.pageName=O[1]),!l&&D&1&&(l=!0,C.storeName=O[0],Pe(()=>l=!1)),!n&&D&4&&(n=!0,C.localKeys=O[2],Pe(()=>n=!1)),e.$set(C),D&1&&i.value!==O[0]&&ke(i,O[0]),O[3]?g?g.p(O,D):(g=Wt(O),g.c(),g.m(s,null)):g&&(g.d(1),g=null)},i(O){h||(Te(e.$$.fragment,O),h=!0)},o(O){we(e.$$.fragment,O),h=!1},d(O){O&&(k(r),k(s)),Se(e,O),g&&g.d(),N=!1,Ye(v)}}}function un(t){const e=/[-:]/g,l=/\..*$/;return`${t}_${new Date().toISOString().replace(e,"").replace(l,"").replace("T","_")}`}function mn(t,e,l){let{pageName:n}=e,{storeName:r}=e,s=[];r=un(n);let a=!1;function c(N){l(3,a=s.includes(N))}function u(N){const v=N.target.value;c(v)}function i(N){r=N,l(0,r)}function m(N){s=N,l(2,s)}function h(){r=this.value,l(0,r)}return t.$$set=N=>{"pageName"in N&&l(1,n=N.pageName),"storeName"in N&&l(0,r=N.storeName)},t.$$.update=()=>{t.$$.dirty&1&&c(r)},[r,n,s,a,u,i,m,h]}class dn extends Me{constructor(e){super(),ye(this,e,mn,fn,ze,{pageName:1,storeName:0})}}function hn(t){let e,l,n,r,s,a,c="Select a parameter-set:",u,i,m;function h(d){t[3](d)}function N(d){t[4](d)}let v={pageName:t[1]};return t[0]!==void 0&&(v.storeName=t[0]),t[2]!==void 0&&(v.localKeys=t[2]),e=new vl({props:v}),je.push(()=>Ae(e,"storeName",h)),je.push(()=>Ae(e,"localKeys",N)),{c(){De(e.$$.fragment),r=I(),s=_("div"),a=_("label"),a.textContent=c,u=I(),i=_("input"),this.h()},l(d){Ee(e.$$.fragment,d),r=P(d),s=p(d,"DIV",{class:!0});var b=S(s);a=p(b,"LABEL",{for:!0,class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-rajgc0"&&(a.textContent=c),u=P(b),i=p(b,"INPUT",{type:!0,id:!0,minlength:!0,maxlength:!0,size:!0,class:!0}),b.forEach(k),this.h()},h(){f(a,"for","storName"),f(a,"class","svelte-1ozd0ey"),f(i,"type","text"),f(i,"id","storName"),i.value=t[0],i.readOnly=!0,f(i,"minlength","4"),f(i,"maxlength","30"),f(i,"size","32"),f(i,"class","svelte-1ozd0ey"),f(s,"class","svelte-1ozd0ey")},m(d,b){Le(e,d,b),J(d,r,b),J(d,s,b),o(s,a),o(s,u),o(s,i),m=!0},p(d,[b]){const T={};b&2&&(T.pageName=d[1]),!l&&b&1&&(l=!0,T.storeName=d[0],Pe(()=>l=!1)),!n&&b&4&&(n=!0,T.localKeys=d[2],Pe(()=>n=!1)),e.$set(T),(!m||b&1&&i.value!==d[0])&&(i.value=d[0])},i(d){m||(Te(e.$$.fragment,d),m=!0)},o(d){we(e.$$.fragment,d),m=!1},d(d){d&&(k(r),k(s)),Se(e,d)}}}function _n(t,e,l){let{pageName:n}=e,{storeName:r}=e,s=[];function a(i){let m=r;return!i.includes(m)&&(i.length>0?m=i[0]:m=""),m}function c(i){r=i,l(0,r),l(2,s)}function u(i){s=i,l(2,s)}return t.$$set=i=>{"pageName"in i&&l(1,n=i.pageName),"storeName"in i&&l(0,r=i.storeName)},t.$$.update=()=>{t.$$.dirty&4&&l(0,r=a(s))},[r,n,s,c,u]}class pn extends Me{constructor(e){super(),ye(this,e,_n,hn,ze,{pageName:1,storeName:0})}}const Re=ul(Ml());function gn(t){let e;return{c(){e=_("canvas"),this.h()},l(l){e=p(l,"CANVAS",{class:!0,width:!0,height:!0}),S(e).forEach(k),this.h()},h(){f(e,"class","mini svelte-z8e4tz"),f(e,"width",Xt),f(e,"height",Xt)},m(l,n){J(l,e,n),t[9](e)},p:Ue,i:Ue,o:Ue,d(l){l&&k(e),t[9](null)}}}const Xt=200;function vn(t,e,l){let n,r;at(t,Re,T=>l(7,n=T)),at(t,Ke,T=>l(8,r=T));let{pageName:s}=e,{fgeom:a}=e,{selFace:c}=e,{zAdjust:u}=e,{simTime:i=0}=e,m,h;function N(T,g){const O=yl(g);O.ruler=!1;const D=m.getContext("2d");D.clearRect(0,0,D.canvas.width,D.canvas.height);try{u.init===0?h=T.getAdjustFull(D.canvas.width,D.canvas.height):h=u,T.draw(D,h,O)}catch(C){console.log(C)}}let v=0;function d(T,g,O,D){const C=a(T,g).fig;if(Object.keys(C).includes(O)){const z=C[O];N(z,D)}else{const z=dl(C);N(z,D)}}Et(()=>{d(i,r[s],c,n),l(6,v=1)});function b(T){je[T?"unshift":"push"](()=>{m=T,l(0,m)})}return t.$$set=T=>{"pageName"in T&&l(1,s=T.pageName),"fgeom"in T&&l(2,a=T.fgeom),"selFace"in T&&l(3,c=T.selFace),"zAdjust"in T&&l(4,u=T.zAdjust),"simTime"in T&&l(5,i=T.simTime)},t.$$.update=()=>{t.$$.dirty&490&&v===1&&d(i,r[s],c,n)},[m,s,a,c,u,i,v,n,r,b]}class Yt extends Me{constructor(e){super(),ye(this,e,vn,gn,ze,{pageName:1,fgeom:2,selFace:3,zAdjust:4,simTime:5})}}function bn(t,e){const l=document.createElement("a");l.setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(e)),l.setAttribute("download",t),l.click(),l.remove()}function bl(t,e,l){const n=/[-:]/g,r=/\..*$/,s=new Date().toISOString().replace(n,"").replace(r,"").replace("T","_"),a=`px_${t}_${s}.json`,c=hl(s,t,e,l);bn(a,c)}function kn(t,e,l){const n=new URL(t),r=2e3;let s=n.toString().length;for(const a of Object.keys(e)){const c=e[a].toString(),u=2+a.length+c.length;n.searchParams.append(encodeURIComponent(a),encodeURIComponent(c)),s+=u}return s>=r&&console.log(`warn547: generateUrl: strLength ${s} larger than strLengthLimit ${r}`),n.toString()}function Kt(t,e,l){const n=t.slice();return n[58]=e[l],n[59]=e,n[60]=l,n}function qt(t,e,l){const n=t.slice();return n[61]=e[l],n[62]=e,n[63]=l,n}function Gt(t,e,l){const n=t.slice();return n[64]=e[l],n[66]=l,n}function Nn(t,e,l){const n=t.slice();return n[64]=e[l],n[66]=l,n}function Tn(t){let e;return{c(){e=K("Load the default parameters ?")},l(l){e=q(l,"Load the default parameters ?")},m(l,n){J(l,e,n)},d(l){l&&k(e)}}}function wn(t){let e,l,n;function r(a){t[34](a)}let s={pageName:t[0].partName};return t[13]!==void 0&&(s.storeName=t[13]),e=new pn({props:s}),je.push(()=>Ae(e,"storeName",r)),{c(){De(e.$$.fragment)},l(a){Ee(e.$$.fragment,a)},m(a,c){Le(e,a,c),n=!0},p(a,c){const u={};c[0]&1&&(u.pageName=a[0].partName),!l&&c[0]&8192&&(l=!0,u.storeName=a[13],Pe(()=>l=!1)),e.$set(u)},i(a){n||(Te(e.$$.fragment,a),n=!0)},o(a){we(e.$$.fragment,a),n=!1},d(a){Se(e,a)}}}function On(t){let e;return{c(){e=K("unknown")},l(l){e=q(l,"unknown")},m(l,n){J(l,e,n)},p:Ue,d(l){l&&k(e)}}}function Cn(t){let e,l,n,r=Ce(t[61].dropdown),s=[];for(let c=0;c<r.length;c+=1)s[c]=Zt(Gt(t,r,c));function a(){t[41].call(e,t[61])}return{c(){e=_("select");for(let c=0;c<s.length;c+=1)s[c].c();this.h()},l(c){e=p(c,"SELECT",{});var u=S(e);for(let i=0;i<s.length;i+=1)s[i].l(u);u.forEach(k),this.h()},h(){t[19][t[0].partName][t[61].name]===void 0&&bt(a)},m(c,u){J(c,e,u);for(let i=0;i<s.length;i+=1)s[i]&&s[i].m(e,null);ot(e,t[19][t[0].partName][t[61].name],!0),l||(n=G(e,"change",a),l=!0)},p(c,u){if(t=c,u[0]&32){r=Ce(t[61].dropdown);let i;for(i=0;i<r.length;i+=1){const m=Gt(t,r,i);s[i]?s[i].p(m,u):(s[i]=Zt(m),s[i].c(),s[i].m(e,null))}for(;i<s.length;i+=1)s[i].d(1);s.length=r.length}u[0]&524321&&ot(e,t[19][t[0].partName][t[61].name])},d(c){c&&k(e),Xe(s,c),l=!1,n()}}}function Dn(t){let e,l,n,r=Ce(["Off","On"]),s=[];for(let c=0;c<2;c+=1)s[c]=Ln(Nn(t,r,c));function a(){t[40].call(e,t[61])}return{c(){e=_("select");for(let c=0;c<2;c+=1)s[c].c();this.h()},l(c){e=p(c,"SELECT",{});var u=S(e);for(let i=0;i<2;i+=1)s[i].l(u);u.forEach(k),this.h()},h(){t[19][t[0].partName][t[61].name]===void 0&&bt(a)},m(c,u){J(c,e,u);for(let i=0;i<2;i+=1)s[i]&&s[i].m(e,null);ot(e,t[19][t[0].partName][t[61].name],!0),l||(n=G(e,"change",a),l=!0)},p(c,u){t=c,u[0]&524321&&ot(e,t[19][t[0].partName][t[61].name])},d(c){c&&k(e),Xe(s,c),l=!1,n()}}}function En(t){let e,l,n,r,s,a,c,u,i,m,h;function N(){t[38].call(e,t[61])}function v(){t[39].call(a,t[61])}return{c(){e=_("input"),s=I(),a=_("input"),this.h()},l(d){e=p(d,"INPUT",{type:!0,min:!0,max:!0,step:!0,class:!0}),s=P(d),a=p(d,"INPUT",{type:!0,min:!0,max:!0,step:!0,class:!0}),this.h()},h(){f(e,"type","number"),f(e,"min",l=t[61].min),f(e,"max",n=t[61].max),f(e,"step",r=t[61].step),f(e,"class","input-number svelte-1g5tt44"),f(a,"type","range"),f(a,"min",c=t[61].min),f(a,"max",u=t[61].max),f(a,"step",i=t[61].step),f(a,"class","svelte-1g5tt44")},m(d,b){J(d,e,b),ke(e,t[19][t[0].partName][t[61].name]),J(d,s,b),J(d,a,b),ke(a,t[19][t[0].partName][t[61].name]),m||(h=[G(e,"input",N),G(e,"change",t[21]),G(a,"change",v),G(a,"input",v),G(a,"change",t[21])],m=!0)},p(d,b){t=d,b[0]&32&&l!==(l=t[61].min)&&f(e,"min",l),b[0]&32&&n!==(n=t[61].max)&&f(e,"max",n),b[0]&32&&r!==(r=t[61].step)&&f(e,"step",r),b[0]&524321&&_t(e.value)!==t[19][t[0].partName][t[61].name]&&ke(e,t[19][t[0].partName][t[61].name]),b[0]&32&&c!==(c=t[61].min)&&f(a,"min",c),b[0]&32&&u!==(u=t[61].max)&&f(a,"max",u),b[0]&32&&i!==(i=t[61].step)&&f(a,"step",i),b[0]&524321&&ke(a,t[19][t[0].partName][t[61].name])},d(d){d&&(k(e),k(s),k(a)),m=!1,Ye(h)}}}function Zt(t){let e,l=t[64]+"",n;return{c(){e=_("option"),n=K(l),this.h()},l(r){e=p(r,"OPTION",{});var s=S(e);n=q(s,l),s.forEach(k),this.h()},h(){e.__value=t[66],ke(e,e.__value)},m(r,s){J(r,e,s),o(e,n)},p(r,s){s[0]&32&&l!==(l=r[64]+"")&&ve(n,l)},d(r){r&&k(e)}}}function Ln(t){let e,l;return{c(){e=_("option"),l=K(t[64]),this.h()},l(n){e=p(n,"OPTION",{});var r=S(e);l=q(r,t[64]),r.forEach(k),this.h()},h(){e.__value=t[66],ke(e,e.__value)},m(n,r){J(n,e,r),o(e,l)},p:Ue,d(n){n&&k(e)}}}function Jt(t){let e,l,n=t[60]+1+"",r,s,a=t[63]+1+"",c,u,i,m,h=t[61].name+"",N,v,d,b,T,g=t[61].unit+"",O,D,C,z=t[61].init+"",F,A,w,E=t[61].min+"",M,U,Y,B=t[61].max+"",y,W,te,ee=t[61].step+"",Q,pe,ue;function me(){return t[37](t[61])}function be(se,Z){return se[61].pType===wt.eNumber?En:se[61].pType===wt.eCheckbox?Dn:se[61].pType===wt.eDropdown?Cn:On}let j=be(t),H=j(t);return{c(){e=_("tr"),l=_("td"),r=K(n),s=K("."),c=K(a),u=I(),i=_("td"),m=_("button"),N=K(h),v=I(),d=_("td"),H.c(),b=I(),T=_("td"),O=K(g),D=I(),C=_("td"),F=K(z),A=I(),w=_("td"),M=K(E),U=I(),Y=_("td"),y=K(B),W=I(),te=_("td"),Q=K(ee),this.h()},l(se){e=p(se,"TR",{class:!0});var Z=S(e);l=p(Z,"TD",{class:!0});var re=S(l);r=q(re,n),s=q(re,"."),c=q(re,a),re.forEach(k),u=P(Z),i=p(Z,"TD",{class:!0});var $=S(i);m=p($,"BUTTON",{class:!0});var he=S(m);N=q(he,h),he.forEach(k),$.forEach(k),v=P(Z),d=p(Z,"TD",{class:!0});var ce=S(d);H.l(ce),ce.forEach(k),b=P(Z),T=p(Z,"TD",{class:!0});var fe=S(T);O=q(fe,g),fe.forEach(k),D=P(Z),C=p(Z,"TD",{class:!0});var x=S(C);F=q(x,z),x.forEach(k),A=P(Z),w=p(Z,"TD",{class:!0});var L=S(w);M=q(L,E),L.forEach(k),U=P(Z),Y=p(Z,"TD",{class:!0});var V=S(Y);y=q(V,B),V.forEach(k),W=P(Z),te=p(Z,"TD",{class:!0});var le=S(te);Q=q(le,ee),le.forEach(k),Z.forEach(k),this.h()},h(){f(l,"class","svelte-1g5tt44"),f(m,"class","svelte-1g5tt44"),f(i,"class","svelte-1g5tt44"),f(d,"class","svelte-1g5tt44"),f(T,"class","svelte-1g5tt44"),f(C,"class","svelte-1g5tt44"),f(w,"class","svelte-1g5tt44"),f(Y,"class","svelte-1g5tt44"),f(te,"class","svelte-1g5tt44"),f(e,"class","svelte-1g5tt44"),Be(e,"changed",t[19][t[0].partName][t[61].name]!==t[61].init)},m(se,Z){J(se,e,Z),o(e,l),o(l,r),o(l,s),o(l,c),o(e,u),o(e,i),o(i,m),o(m,N),o(e,v),o(e,d),H.m(d,null),o(e,b),o(e,T),o(T,O),o(e,D),o(e,C),o(C,F),o(e,A),o(e,w),o(w,M),o(e,U),o(e,Y),o(Y,y),o(e,W),o(e,te),o(te,Q),pe||(ue=G(m,"click",me),pe=!0)},p(se,Z){t=se,Z[0]&32&&h!==(h=t[61].name+"")&&ve(N,h),j===(j=be(t))&&H?H.p(t,Z):(H.d(1),H=j(t),H&&(H.c(),H.m(d,null))),Z[0]&32&&g!==(g=t[61].unit+"")&&ve(O,g),Z[0]&32&&z!==(z=t[61].init+"")&&ve(F,z),Z[0]&32&&E!==(E=t[61].min+"")&&ve(M,E),Z[0]&32&&B!==(B=t[61].max+"")&&ve(y,B),Z[0]&32&&ee!==(ee=t[61].step+"")&&ve(Q,ee),Z[0]&524321&&Be(e,"changed",t[19][t[0].partName][t[61].name]!==t[61].init)},d(se){se&&k(e),H.d(),pe=!1,ue()}}}function Qt(t){let e,l,n=t[60]+1+"",r,s,a,c=t[58].sectionName+"",u,i,m,h,N,v,d,b="",T,g,O,D,C;function z(){t[36].call(N,t[58])}let F=Ce(t[58].params),A=[];for(let w=0;w<F.length;w+=1)A[w]=Jt(qt(t,F,w));return{c(){e=_("tr"),l=_("td"),r=K(n),s=I(),a=_("td"),u=K(c),i=I(),m=_("td"),h=_("label"),N=_("input"),v=I(),d=_("span"),d.innerHTML=b,T=I(),g=_("tbody");for(let w=0;w<A.length;w+=1)A[w].c();O=I(),this.h()},l(w){e=p(w,"TR",{class:!0});var E=S(e);l=p(E,"TD",{class:!0});var M=S(l);r=q(M,n),M.forEach(k),s=P(E),a=p(E,"TD",{colspan:!0,class:!0});var U=S(a);u=q(U,c),U.forEach(k),i=P(E),m=p(E,"TD",{colspan:!0,class:!0});var Y=S(m);h=p(Y,"LABEL",{class:!0});var B=S(h);N=p(B,"INPUT",{type:!0,class:!0}),v=P(B),d=p(B,"SPAN",{class:!0,"data-svelte-h":!0}),oe(d)!=="svelte-1qufua2"&&(d.innerHTML=b),B.forEach(k),Y.forEach(k),E.forEach(k),T=P(w),g=p(w,"TBODY",{class:!0});var y=S(g);for(let W=0;W<A.length;W+=1)A[W].l(y);O=P(y),y.forEach(k),this.h()},h(){f(l,"class","svelte-1g5tt44"),f(a,"colspan","4"),f(a,"class","svelte-1g5tt44"),f(N,"type","checkbox"),f(N,"class","svelte-1g5tt44"),f(d,"class","svelte-1g5tt44"),f(h,"class","svelte-1g5tt44"),f(m,"colspan","3"),f(m,"class","svelte-1g5tt44"),f(e,"class","separator svelte-1g5tt44"),f(g,"class","svelte-1g5tt44"),Be(g,"collaps",t[18][t[58].sectionID])},m(w,E){J(w,e,E),o(e,l),o(l,r),o(e,s),o(e,a),o(a,u),o(e,i),o(e,m),o(m,h),o(h,N),N.checked=t[18][t[58].sectionID],o(h,v),o(h,d),J(w,T,E),J(w,g,E);for(let M=0;M<A.length;M+=1)A[M]&&A[M].m(g,null);o(g,O),D||(C=G(N,"change",z),D=!0)},p(w,E){if(t=w,E[0]&32&&c!==(c=t[58].sectionName+"")&&ve(u,c),E[0]&262176&&(N.checked=t[18][t[58].sectionID]),E[0]&271056929){F=Ce(t[58].params);let M;for(M=0;M<F.length;M+=1){const U=qt(t,F,M);A[M]?A[M].p(U,E):(A[M]=Jt(U),A[M].c(),A[M].m(g,O))}for(;M<A.length;M+=1)A[M].d(1);A.length=F.length}E[0]&262176&&Be(g,"collaps",t[18][t[58].sectionID])},d(w){w&&(k(e),k(T),k(g)),Xe(A,w),D=!1,C()}}}function Sn(t){let e,l="Copy this URL and send it to your friends!",n,r,s;return{c(){e=_("p"),e.textContent=l,n=I(),r=_("p"),s=K(t[15]),this.h()},l(a){e=p(a,"P",{"data-svelte-h":!0}),oe(e)!=="svelte-1kscrpk"&&(e.textContent=l),n=P(a),r=p(a,"P",{class:!0});var c=S(r);s=q(c,t[15]),c.forEach(k),this.h()},h(){f(r,"class","cUrl svelte-1g5tt44")},m(a,c){J(a,e,c),J(a,n,c),J(a,r,c),o(r,s)},p(a,c){c[0]&32768&&ve(s,a[15])},d(a){a&&(k(e),k(n),k(r))}}}function jn(t){let e,l,n;function r(a){t[45](a)}let s={pageName:t[0].partName};return t[14]!==void 0&&(s.storeName=t[14]),e=new dn({props:s}),je.push(()=>Ae(e,"storeName",r)),{c(){De(e.$$.fragment)},l(a){Ee(e.$$.fragment,a)},m(a,c){Le(e,a,c),n=!0},p(a,c){const u={};c[0]&1&&(u.pageName=a[0].partName),!l&&c[0]&16384&&(l=!0,u.storeName=a[14],Pe(()=>l=!1)),e.$set(u)},i(a){n||(Te(e.$$.fragment,a),n=!0)},o(a){we(e.$$.fragment,a),n=!1},d(a){Se(e,a)}}}function In(t){let e,l,n="Parameters",r,s,a,c="Load Params from File",u,i,m,h,N="Set Params Default",v,d,b="Load Params from localStorage",T,g,O,D,C,z,F,A,w,E,M,U='<tr class="svelte-1g5tt44"><td class="svelte-1g5tt44">#</td> <td class="svelte-1g5tt44">Parameter name</td> <td class="svelte-1g5tt44">Value</td> <td class="svelte-1g5tt44">Unit</td> <td class="svelte-1g5tt44">Default</td> <td class="svelte-1g5tt44">Min</td> <td class="svelte-1g5tt44">Max</td> <td class="svelte-1g5tt44">Step</td></tr>',Y,B,y,W,te="Comment:",ee,Q,pe,ue,me="Save Parameters to File",be,j,H="Save Parameters as URL",se,Z,re="Save Parameters to localStorage",$,he,ce,fe,x,L,V,le,_e,ge,ie,Oe,Je,Qe,xe,qe,pt,R,ae,Ne,Fe,He;function $e(X){t[33](X)}let rt={okName:"Overwrite Parameters",okFunc:t[24],$$slots:{default:[Tn]},$$scope:{ctx:t}};t[9]!==void 0&&(rt.modalOpen=t[9]),g=new gt({props:rt}),je.push(()=>Ae(g,"modalOpen",$e));function kt(X){t[35](X)}let it={okName:"Load Parameters",okFunc:t[25],$$slots:{default:[wn]},$$scope:{ctx:t}};t[10]!==void 0&&(it.modalOpen=t[10]),C=new gt({props:it}),je.push(()=>Ae(C,"modalOpen",kt));let et=Ce(t[5]),Ie=[];for(let X=0;X<et.length;X+=1)Ie[X]=Qt(Kt(t,et,X));function Lt(X){t[44](X)}let Ve={okName:"Done",okFunc:Pn,sizeLarge:!0,$$slots:{default:[Sn]},$$scope:{ctx:t}};t[11]!==void 0&&(Ve.modalOpen=t[11]),he=new gt({props:Ve}),je.push(()=>Ae(he,"modalOpen",Lt));function Nl(X){t[46](X)}let St={okName:"Save into localStorage",okFunc:t[26],$$slots:{default:[jn]},$$scope:{ctx:t}};t[12]!==void 0&&(St.modalOpen=t[12]),x=new gt({props:St}),je.push(()=>Ae(x,"modalOpen",Nl));function Tl(X){t[47](X)}let jt={svgPath:t[16]};return t[17]!==void 0&&(jt.modalOpen=t[17]),le=new gl({props:jt}),je.push(()=>Ae(le,"modalOpen",Tl)),qe=new Yt({props:{pageName:t[0].partName,fgeom:t[1],selFace:t[2],zAdjust:t[20],simTime:t[4]}}),ae=new Yt({props:{pageName:t[0].partName,fgeom:t[1],selFace:t[2],zAdjust:t[3],simTime:t[4]}}),{c(){e=_("section"),l=_("h2"),l.textContent=n,r=I(),s=_("main"),a=_("label"),a.textContent=c,u=I(),i=_("input"),m=I(),h=_("button"),h.textContent=N,v=I(),d=_("button"),d.textContent=b,T=I(),De(g.$$.fragment),D=I(),De(C.$$.fragment),F=I(),A=_("textarea"),w=I(),E=_("table"),M=_("thead"),M.innerHTML=U,Y=I();for(let X=0;X<Ie.length;X+=1)Ie[X].c();B=I(),y=_("div"),W=_("label"),W.textContent=te,ee=I(),Q=_("input"),pe=I(),ue=_("button"),ue.textContent=me,be=I(),j=_("button"),j.textContent=H,se=I(),Z=_("button"),Z.textContent=re,$=I(),De(he.$$.fragment),fe=I(),De(x.$$.fragment),V=I(),De(le.$$.fragment),ge=I(),ie=_("button"),Oe=_("img"),Qe=I(),xe=_("div"),De(qe.$$.fragment),pt=I(),R=_("div"),De(ae.$$.fragment),this.h()},l(X){e=p(X,"SECTION",{class:!0});var ne=S(e);l=p(ne,"H2",{class:!0,"data-svelte-h":!0}),oe(l)!=="svelte-1mc497a"&&(l.textContent=n),r=P(ne),s=p(ne,"MAIN",{class:!0});var de=S(s);a=p(de,"LABEL",{for:!0,class:!0,"data-svelte-h":!0}),oe(a)!=="svelte-zt7rok"&&(a.textContent=c),u=P(de),i=p(de,"INPUT",{id:!0,type:!0,accept:!0,class:!0}),m=P(de),h=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(h)!=="svelte-1typ5"&&(h.textContent=N),v=P(de),d=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(d)!=="svelte-187bpo6"&&(d.textContent=b),T=P(de),Ee(g.$$.fragment,de),D=P(de),Ee(C.$$.fragment,de),F=P(de),A=p(de,"TEXTAREA",{rows:!0,cols:!0,wrap:!0,class:!0}),S(A).forEach(k),w=P(de),E=p(de,"TABLE",{class:!0});var tt=S(E);M=p(tt,"THEAD",{class:!0,"data-svelte-h":!0}),oe(M)!=="svelte-1szl7uo"&&(M.innerHTML=U),Y=P(tt);for(let Ge=0;Ge<Ie.length;Ge+=1)Ie[Ge].l(tt);tt.forEach(k),B=P(de),y=p(de,"DIV",{class:!0});var lt=S(y);W=p(lt,"LABEL",{for:!0,"data-svelte-h":!0}),oe(W)!=="svelte-gqskth"&&(W.textContent=te),ee=P(lt),Q=p(lt,"INPUT",{type:!0,id:!0,maxlength:!0,size:!0}),lt.forEach(k),pe=P(de),ue=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(ue)!=="svelte-1ny58g0"&&(ue.textContent=me),be=P(de),j=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(j)!=="svelte-11or0m2"&&(j.textContent=H),se=P(de),Z=p(de,"BUTTON",{class:!0,"data-svelte-h":!0}),oe(Z)!=="svelte-5zdtrl"&&(Z.textContent=re),$=P(de),Ee(he.$$.fragment,de),fe=P(de),Ee(x.$$.fragment,de),de.forEach(k),V=P(ne),Ee(le.$$.fragment,ne),ge=P(ne),ie=p(ne,"BUTTON",{class:!0});var ut=S(ie);Oe=p(ut,"IMG",{src:!0,alt:!0,class:!0}),ut.forEach(k),Qe=P(ne),xe=p(ne,"DIV",{class:!0});var mt=S(xe);Ee(qe.$$.fragment,mt),mt.forEach(k),pt=P(ne),R=p(ne,"DIV",{class:!0});var nt=S(R);Ee(ae.$$.fragment,nt),nt.forEach(k),ne.forEach(k),this.h()},h(){f(l,"class","svelte-1g5tt44"),f(a,"for","loadFParams"),f(a,"class","fileUpload svelte-1g5tt44"),f(i,"id","loadFParams"),f(i,"type","file"),f(i,"accept","text/plain, application/json"),f(i,"class","svelte-1g5tt44"),f(h,"class","svelte-1g5tt44"),f(d,"class","svelte-1g5tt44"),f(A,"rows","3"),f(A,"cols","80"),A.readOnly=!0,f(A,"wrap","off"),A.value=t[7],f(A,"class","svelte-1g5tt44"),Be(A,"colorWarn",t[8]),f(M,"class","svelte-1g5tt44"),f(E,"class","svelte-1g5tt44"),f(W,"for","inComment"),f(Q,"type","text"),f(Q,"id","inComment"),f(Q,"maxlength","150"),f(Q,"size","70"),f(y,"class","comment svelte-1g5tt44"),f(ue,"class","svelte-1g5tt44"),f(j,"class","svelte-1g5tt44"),f(Z,"class","svelte-1g5tt44"),f(s,"class","svelte-1g5tt44"),ht(Oe.src,Je=t[16])||f(Oe,"src",Je),f(Oe,"alt",t[16]),f(Oe,"class","svelte-1g5tt44"),f(ie,"class","side-img svelte-1g5tt44"),f(xe,"class","mini-canvas svelte-1g5tt44"),f(R,"class","mini-canvas svelte-1g5tt44"),f(e,"class","svelte-1g5tt44")},m(X,ne){J(X,e,ne),o(e,l),o(e,r),o(e,s),o(s,a),o(s,u),o(s,i),o(s,m),o(s,h),o(s,v),o(s,d),o(s,T),Le(g,s,null),o(s,D),Le(C,s,null),o(s,F),o(s,A),o(s,w),o(s,E),o(E,M),o(E,Y);for(let de=0;de<Ie.length;de+=1)Ie[de]&&Ie[de].m(E,null);o(s,B),o(s,y),o(y,W),o(y,ee),o(y,Q),ke(Q,t[6]),o(s,pe),o(s,ue),o(s,be),o(s,j),o(s,se),o(s,Z),o(s,$),Le(he,s,null),o(s,fe),Le(x,s,null),o(e,V),Le(le,e,null),o(e,ge),o(e,ie),o(ie,Oe),o(e,Qe),o(e,xe),Le(qe,xe,null),o(e,pt),o(e,R),Le(ae,R,null),Ne=!0,Fe||(He=[G(i,"change",t[22]),G(h,"click",t[31]),G(d,"click",t[32]),G(Q,"input",t[42]),G(ue,"click",t[23]),G(j,"click",t[27]),G(Z,"click",t[43]),G(ie,"click",t[29])],Fe=!0)},p(X,ne){const de={};ne[2]&64&&(de.$$scope={dirty:ne,ctx:X}),!O&&ne[0]&512&&(O=!0,de.modalOpen=X[9],Pe(()=>O=!1)),g.$set(de);const tt={};if(ne[0]&8193|ne[2]&64&&(tt.$$scope={dirty:ne,ctx:X}),!z&&ne[0]&1024&&(z=!0,tt.modalOpen=X[10],Pe(()=>z=!1)),C.$set(tt),(!Ne||ne[0]&128)&&(A.value=X[7]),(!Ne||ne[0]&256)&&Be(A,"colorWarn",X[8]),ne[0]&271319073){et=Ce(X[5]);let We;for(We=0;We<et.length;We+=1){const It=Kt(X,et,We);Ie[We]?Ie[We].p(It,ne):(Ie[We]=Qt(It),Ie[We].c(),Ie[We].m(E,null))}for(;We<Ie.length;We+=1)Ie[We].d(1);Ie.length=et.length}ne[0]&64&&Q.value!==X[6]&&ke(Q,X[6]);const lt={};ne[0]&32768|ne[2]&64&&(lt.$$scope={dirty:ne,ctx:X}),!ce&&ne[0]&2048&&(ce=!0,lt.modalOpen=X[11],Pe(()=>ce=!1)),he.$set(lt);const ut={};ne[0]&16385|ne[2]&64&&(ut.$$scope={dirty:ne,ctx:X}),!L&&ne[0]&4096&&(L=!0,ut.modalOpen=X[12],Pe(()=>L=!1)),x.$set(ut);const mt={};ne[0]&65536&&(mt.svgPath=X[16]),!_e&&ne[0]&131072&&(_e=!0,mt.modalOpen=X[17],Pe(()=>_e=!1)),le.$set(mt),(!Ne||ne[0]&65536&&!ht(Oe.src,Je=X[16]))&&f(Oe,"src",Je),(!Ne||ne[0]&65536)&&f(Oe,"alt",X[16]);const nt={};ne[0]&1&&(nt.pageName=X[0].partName),ne[0]&2&&(nt.fgeom=X[1]),ne[0]&4&&(nt.selFace=X[2]),ne[0]&16&&(nt.simTime=X[4]),qe.$set(nt);const Ge={};ne[0]&1&&(Ge.pageName=X[0].partName),ne[0]&2&&(Ge.fgeom=X[1]),ne[0]&4&&(Ge.selFace=X[2]),ne[0]&8&&(Ge.zAdjust=X[3]),ne[0]&16&&(Ge.simTime=X[4]),ae.$set(Ge)},i(X){Ne||(Te(g.$$.fragment,X),Te(C.$$.fragment,X),Te(he.$$.fragment,X),Te(x.$$.fragment,X),Te(le.$$.fragment,X),Te(qe.$$.fragment,X),Te(ae.$$.fragment,X),Ne=!0)},o(X){we(g.$$.fragment,X),we(C.$$.fragment,X),we(he.$$.fragment,X),we(x.$$.fragment,X),we(le.$$.fragment,X),we(qe.$$.fragment,X),we(ae.$$.fragment,X),Ne=!1},d(X){X&&k(e),Se(g),Se(C),Xe(Ie,X),Se(he),Se(x),Se(le),Se(qe),Se(ae),Fe=!1,Ye(He)}}}function Pn(){}function An(t){const e={};for(const l of t)e[l.sectionID]=l.sectionVisible;return e}function Un(t,e,l){let n,r;at(t,Ke,R=>l(19,n=R)),at(t,ql,R=>l(48,r=R));const s=ml();let{pDef:a}=e,{fgeom:c}=e,{selFace:u}=e,{zAdjust:i}=e,{simTime:m=0}=e;const h=_l();let N="";function v(){s("paramChg",{foo:"bla"})}function d(R,ae){let Ne="",Fe=!1;R!==a.partName&&(Ne+=`warn361: read partName: '${R}' expected partName: '${a.partName}'
|
|
2
2
|
`,Fe=!0);let He=0,$e=0,rt=0;const kt=[];for(const Ve of a.params)kt.push(Ve.name),Object.hasOwn(ae,Ve.name)?(He+=1,n[a.partName][Ve.name]===ae[Ve.name]?rt+=1:Il(Ke,n[a.partName][Ve.name]=ae[Ve.name],n)):$e+=1;let it=0;for(const Ve of Object.keys(ae))kt.includes(Ve)||(it+=1,Ne+=`warn363: parameter ${Ve} not in the scope of the design (${it})
|
|
3
3
|
`);const et=it>0;return Ne+=`Params loaded at ${new Date().toLocaleTimeString()} :`,Ne+=` def-nb: ${Object.keys(a.params).length}`,Ne+=`, cover-nb: ${He}, uncover-nb: ${$e}
|
|
4
4
|
`,Ne+=` load-nb: ${Object.keys(ae).length}`,Ne+=`, equal-nb: ${rt}, changed-nb: ${He-rt}`,Ne+=`, out-of-scope: ${it}`,[Ne,Fe||et]}let b="",T=!1;function g(){{const R=new URLSearchParams(r.url.search),ae={};for(const[Ne,Fe]of R){const He=Number(Fe);isNaN(He)||(ae[Ne]=He)}Object.keys(ae).length>0&&l(7,[b,T]=d(a.partName,ae),b,l(8,T))}}function O(){g(),v()}Et(()=>{O()});function D(R){try{const[ae]=Fl(R);l(7,[b,T]=d(ae.partName,ae.pVal),b,l(8,T)),l(6,N=ae.comment),v()}catch(ae){let Ne=`err723: error by parsing parameter file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"
|
|
1
|
+
{"version":"1715266244082"}
|